Re: [racket-users] (namespace-variable-value) not working with a struct definition?

2016-07-09 Thread mattapiroglu
On Saturday, June 25, 2016 at 8:13:04 AM UTC+10, Matthew Flatt wrote: > > For what it's worth, I recommend avoiding `namespace-variable-value`. > There's usually a better way, but it depends on what you're trying to > do. > Thanks much for the lead, I am now using eval with relevant custom name

Re: [racket-users] (namespace-variable-value) not working with a struct definition?

2016-06-24 Thread Matt A. Peerson
On Saturday, 25 June 2016 08:20:30 UTC+10, Matt A. Peerson wrote: > On Saturday, 25 June 2016 08:13:04 UTC+10, Matthew Flatt wrote: > > If you write > > > > (struct point (x y)) > > > > then `point` is bound as syntax that both expands to the `point` > > constructor and provides static inform

Re: [racket-users] (namespace-variable-value) not working with a struct definition?

2016-06-24 Thread Matt A. Peerson
On Saturday, 25 June 2016 08:13:04 UTC+10, Matthew Flatt wrote: > If you write > > (struct point (x y)) > > then `point` is bound as syntax that both expands to the `point` > constructor and provides static information about the point` structure > (as used, for example, by `match`). > > You c

Re: [racket-users] (namespace-variable-value) not working with a struct definition?

2016-06-24 Thread Matthew Flatt
If you write (struct point (x y)) then `point` is bound as syntax that both expands to the `point` constructor and provides static information about the point` structure (as used, for example, by `match`). You could avoid the indirection through syntax, sacrificing static information, by addin