- parsing of polydots values was fixed
- certain polydots error cases are now reported
- the custom application rule for values was fixed
Closes PR 13365
Please merge to 5.3.2
This fixes several issues:
- `Parameter` generates impersonator contracts correctly
- `Any` handling now copies immutable data when possible
- `Any` now recognizes more atomic base types
Merge to 5.3.1.
The contract now has two major differences:
- It raises an error when it would have to wrap.
- It uses chaperones to delay errors as long as possible
In general, using `Any` as a type when exporting to untyped
code will now just work, unless the untyped code tries to
communicate values back to the typed side, in which case an
immediate error will be raised.
Much of the implementation comes from the membrane design
from [Strickland et al, OOPSLA 2012].
Each typed module now defines a submodule named `type-decl`.
This module performs the type environment initialization (along
with other environment updates) when invoked. Additionall,
every typed module, when invoked, performs a for-syntax addition
to a list specifying the submodules that need invocation.
This invocation is then performed by the `#%module-begin` from
Typed Racket.
The `type-decl` module always goes at the beginning of the
expanded module, so that it's available at syntax-time for all
the other submodules. This involved adding pre- and post-
syntaxes for the results of typechecking.
This allows significant runtime dependency reduction from the
main `typed/racket` and `typed/racket/base` languages (not yet
complete).
Caveats:
- keyword function definitions do not define static
bindings, thus limiting optimization opportunities
- can't use `define:`, `lambda:`, etc with keywords
- error messages sometimes expose the implementation
- the optimizer skips most of the generated code for
keyword functions definitions (user-level code is
optimized)