The Racket repository
![]() Nested splicing forms would lead to an "ambigious binding" error when the nested forms bind the same name, such as in (splicing-let ([a 1]) (splicing-let ([a 2]) (define x a))) The problem is that splicing is implemented by adding a scope to everything in the form's body, but removing it back off the identifiers of a definition (so the `x` above ends up with no new scopes). Meanwhile, a splicing form expands to a set of definitions, where the locally bound identifier keeps the extra scope (unlike definitions from the body). A local identifier for a nested splicing form would then keep the inner scope but lose the outer scope, while a local identifier from the outer splicing form would keep the outer scope but no have the inner one --- leading to ambiguity. The solution in this commit is to annotate a local identifier for a splicing form with a property that says "intended to be local", so the nested definition will keep the scope for the outer splicing form as well as the inner one. It's not clear that this is the right approach, but it's the best idea I have for now. |
||
---|---|---|
pkgs | ||
racket | ||
.gitattributes | ||
.gitignore | ||
.mailmap | ||
.travis.yml | ||
appveyor.yml | ||
INSTALL.txt | ||
Makefile | ||
README.txt |
This is the source code for the main Racket distribution. See "INSTALL.txt" for information on building Racket. License ------- Racket Copyright (c) 2010-2014 PLT Design Inc. Racket is distributed under the GNU Lesser General Public License (LGPL). This implies that you may link Racket into proprietary applications, provided you follow the rules stated in the LGPL. You can also modify Racket; if you distribute a modified version, you must distribute it under the terms of the LGPL, which in particular states that you must release the source code for the modified software. See racket/src/COPYING_LESSER.txt for more information.