Is this possible with newLisp

Started by bob, January 14, 2016, 04:31:24 AM

Previous topic - Next topic

bob

Hi my name is Bob Ueland and I'm a programmer from Sweden. I'm totally new to newLisp trying to decide if I could use newLisp in my projects.



I write Mac OS X apps using Objective-C. Some parts of the program I would like to express in newLisp rather than in Objective-C. So would it be possible to have one or more text files, containing newLisp code, as a resource  in my Objective-C app, and let my app execute the newLisp code dynamically whenever needed? (By execute I mean calling newLisp functions with arguments from Objective-C code.)

Lutz

#1
On OS X use makefile_darwinLP64_utf8_lib to build a newlisp.dylib shared library. Here is a C example on how to import it from C (second example in the chapter):



http://www.newlisp.org/downloads/CodePatterns.html#toc-24">http://www.newlisp.org/downloads/CodePa ... tml#toc-24">http://www.newlisp.org/downloads/CodePatterns.html#toc-24



The library will keep state between different calls.



Ps: the example also shows hpr to use [text] [/text] tags for bigger source code portions.