I have done some further digging. Looks like it is non-trivial to remove
the top-level-bind-scope and still preserve the current behaviors of
top-level `define-values` and `define-syntaxes`. In particular, through
`as-expand-time-top-level-bindings` in "expander/expand/bind-top.rkt", both
top-l
Hi Matthew,
Thanks for the explanations. But I'm still not convinced that the
top-level-bind-scope is needed. This is my current understanding. The
purpose of the top-level-bind-scope is to support recursion better at the
top level. But for the case of `(define-values (x) ...)`, if `x` is not
> On Mar 23, 2020, at 13:46, George Neuner wrote:
>
> I've run into this problem before ... I don't recall the official
> explanation, but my takeaway was that Racket does not permit you to
> directly *export* a value - you have to export a function or macro
> that produces the value.
>
> E.g.,
At Mon, 23 Mar 2020 01:45:40 -0700 (PDT), Yongming Shen wrote:
> I tried the example you gave for my first question and it resulted in an
> error.
Oops --- you're right. I lost track of what we try to make work at the
top level.
> I think this is because `(define-values (x) ...)` expands `...` w
Hi Matthew,
Thank you for the quick reply!
I tried the example you gave for my first question and it resulted in an
error.
I have the following as `module-that-defines-fib`:
#lang racket
(provide fib)
(define fib "fib")
And this is the error that I got (using Racket 7.6):
; applicatio
At Sat, 21 Mar 2020 00:00:07 -0700 (PDT), Yongming Shen wrote:
> First, in the source file expander/expand/bind-top.rkt, there is a comment
> that says "When compiling `(define-values (x) ...)` at the top level,
> we'd like to bind `x` so that a reference in the "..." will point back to
> the de
6 matches
Mail list logo