chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Determine if program has been compiled


From: Mario Domenech Goulart
Subject: Re: [Chicken-users] Determine if program has been compiled
Date: Sat, 12 Jul 2014 18:18:30 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Hi Christopher,

On Sat, 12 Jul 2014 11:09:24 -0700 Christopher Collins <address@hidden> wrote:

> Is there a way to determine, in code, whether a chicken program has
> been compiled? I am thinking of something similar to:
>
> (cond-expand
> (chicken-script ... )
>
> ...but with an identifer different from "chicken-script".
>
> It is possible that I'm asking the wrong question. My underlying
> problem is: I want my program to behave one way when I load it from
> within csi, and another way when I either execute it with "csi -
> script" or compile it and execute the binary. In particular, to make
> debugging easier, I want to skip command line parsing when I load the
> code in csi.  The cond-expand,chicken-script form lets me determine
> when the program was run with "csi -script". However, it does not
> solve the compile-and-run scenario; the resulting executable behaves
> as though it were loaded into csi.

Maybe http://wiki.call-cc.org/compiler%20or%20interpreter can be
helpful.

Best wishes.
Mario
-- 
http://parenteses.org/mario



reply via email to

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