[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] compiled program with macros raises unbound-variable
Re: [Chicken-users] compiled program with macros raises unbound-variable error
Thu, 08 Mar 2007 12:26:33 +0100
Thunderbird 184.108.40.206 (X11/20070103)
felix winkelmann schrieb:
> On 3/8/07, foobar <address@hidden> wrote:
>> Hi list,
>> i've tried to compile a file that uses some macros defined with
>> I compiled it using: csc -R tinyclos foo.scm
>> So nothing special sofar.
>> The file compiles without warnings or errors.
>> Another file compiled to a shared-library
>> using csc -s cps.scm.
>> This file requires the macros via
>> (require 'cps-syntax).
> Is cps-syntax a source file containing macros?
> Then you have to
> make those macros available at _compile-time_, or the
> compiler will not see them. "(require ...)" loads code at run-time,
> not at compile-time. Try "require-for-syntax".
I tried it and it worked :) Thanks very much.
I didn't know that there is a special syntax for such things.
I tried it using csc -run-time-macros but that didn't work
I'll consult the manual for the various forms to require files.