chicken-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-hackers] define-record, etc. patch to chicken 4


From: felix winkelmann
Subject: Re: [Chicken-hackers] define-record, etc. patch to chicken 4
Date: Mon, 9 Feb 2009 13:09:29 +0100

On Sat, Feb 7, 2009 at 10:40 AM, Jim Ursetto <address@hidden> wrote:
> define-record, define-record-type and define-record-printer do not
> take the module namespace into account, so records that are defined in
> different modules--but have the same base name--may conflict, giving
> strange results or crashing your program.  The attached patch
> qualifies the structure name with the current module name, which seems
> to work.

The record-definition macros take a record name and use it as a tag
for structures, and because the expansion is a quoted symbol, it
will not be qualified, so it is basically a sort of

  (vector 'tag slotval1 ...)

 I'm not sure whether it is a good idea to generally qualify record tags.

Thanks for the patch - I will evaluate it and try to think of what happens
in the case we do this.


cheers,
felix




reply via email to

[Prev in Thread] Current Thread [Next in Thread]