Re: [racket-users] syntax-properties, local-expand, and a struct

2016-09-28 Thread Alexis King
> Unfortunately, there are probably many such buggy macros, since I don't think > most people have a clear idea when to copy properties when using > datum->syntax. This is key, and unfortunately I’m becoming more and more convinced that there’s no one good answer in the presence of the relativel

Re: [racket-users] syntax-properties, local-expand, and a struct

2016-09-28 Thread Ryan Culpepper
On 9/28/16 12:04 PM, William J. Bowman wrote: On Fri, Sep 23, 2016 at 02:58:23PM -0400, Ryan Culpepper wrote: It appears that the constructor macro (implemented by self-ctor-transformer in racket/private/define-struct.rkt) transfers the syntax properties from the macro use to its expansion (see

Re: [racket-users] syntax-properties, local-expand, and a struct

2016-09-28 Thread 'William J. Bowman' via Racket Users
On Fri, Sep 23, 2016 at 02:58:23PM -0400, Ryan Culpepper wrote: > It appears that the constructor macro (implemented by self-ctor-transformer > in racket/private/define-struct.rkt) transfers the syntax properties from > the macro use to its expansion (see the datum->syntax in the first > syntax-cas

Re: [racket-users] syntax-properties, local-expand, and a struct

2016-09-23 Thread Ryan Culpepper
On 09/23/2016 02:43 PM, 'William J. Bowman' via Racket Users wrote: Under certain conditions, the value of a syntax property is duplicated. I can't figure out why, or if this is a bug, and any advice would be appreciated. I've attached the smallest program that generates this behavior that I've

[racket-users] syntax-properties, local-expand, and a struct

2016-09-23 Thread 'William J. Bowman' via Racket Users
Under certain conditions, the value of a syntax property is duplicated. I can't figure out why, or if this is a bug, and any advice would be appreciated. I've attached the smallest program that generates this behavior that I've managed to find. The conditions seem to be: 1. Write a syntax obje