On Sun, Jul 14, 2013 at 10:21 PM, Andy Hefner <ahef...@gmail.com> wrote:

>
> I don't think we're thinking the same thing. I don't want to do
> anything with the variable from Lisp, I simply want it defined in a
> scope that it such that the variable will continue to exist and be
> visible within other inline C blocks, and given a name that won't
> clash with variables generated by the ECL compiler. I suppose it is a
> different feature than what you described, since it need not
> correspond to a lisp variable at all.


Ok, this can be done with the new C-PROGN special form.

   (ffi:c-progn (a)
     "int my_variable;"
     (some-lisp-form)
     "my_variable = 2"
     (more computations)
     ...)))

Here "my_variable" is only for the C world and it's scope is preserved
along the computation.


-- 
Instituto de FĂ­sica Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
http://juanjose.garciaripoll.googlepages.com
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Ecls-list mailing list
Ecls-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ecls-list

Reply via email to