Hi, Andy Wingo <wi...@pobox.com> writes:
> On Sun 06 Mar 2011 23:26, l...@gnu.org (Ludovic Courtès) writes: > >> Andreas Rottmann <a.rottm...@gmx.at> writes: >> >>> The expansion of `define-inlinable' contained an expression, which made >>> SRFI-9's `define-record-type' fail in non-toplevel contexts ("definition >>> used in expression context"). >> >> SRFI-9 says “Record-type definitions may only occur at top-level”, and >> I’m inclined to stick to it. If we diverge, then people could write >> code thinking it’s portable SRFI-9 code while it’s not. > > Does anyone actually care about this? We provide many compatible > extensions to standard interfaces. It seems like this would be an > "unnecessary restriction which makes `let-record-type' seem necessary". OK, I lost. ;-) But, can we: 1. Document the extension. 2. Choose PROC-NAME such that -Wunused-toplevel won’t complain. There’s a trick for this: if it contains white space, then -Wunused-toplevel won’t complain; however, it has to be generated deterministically because it can appear in other compilation units, so we can’t use ‘generate-temporaries’ here. Thanks, Ludo’.