Re: Sadness in my heart...
Yes, and this is when water hits the rock: using CL as "glue language" for the foreing APIs will not make the SW "better" and IMNSHO CL is not the best language for this "mundane" chore.
Also there is the "impedance mismatch" between the imperative based APIs and the FP "oriented" Lisp jargon where you end programming in a style where the constructs of Lisp that make its use more apealing quickly disapear in the system.
Also there is the "impedance mismatch" between the imperative based APIs and the FP "oriented" Lisp jargon where you end programming in a style where the constructs of Lisp that make its use more apealing quickly disapear in the system.
The sad news is that for a lot of problems the kernel which justifies the language(s) which will be used for the application development: business app? a CRUD application which requires a GUI painter and a streamlined API to access the database of the business; scientific app? An app which should pipe a lot of procedures/functions in the problem domain, which is easier to do in language similar to the one employed in the library(ies) to be used.
My 0.01999999 cents
--
Cesar Rabak
De: cstacy@dtpq.com
Enviada: Quinta-feira, 28 de Abril de 2016 14:33
Para: mgcheung@gmail.com
Assunto: Sadness in my heart...
All the Common Lisp implementations support calling foreign functions
through a variety of interfaces, notably UFFI and CFFI (which are portable).
There are also automatic tools for doing the wrapping (i.e. SWIG).
Those are for C/C++. There are also interfaces for Java and .NET libraries (i.e. FOIL).
Each implementation (Lisp vendor) may also have proprietary interface systems.
In Franz’s Allegro Common Lisp, to get at Java for example, you can just write
things like “def-java-class” and “def-java-method” to define magical CLOS classes.
In Lispworks for C (and FORTRAN !) see http://www.lispworks.com/documentation/lcl50/aug/aug-68.html
Of course, there are also Lisp implementations (including Common Lisp)
that target the JVM, if that’s what you’re after. There’s of course Clojure,
which is a non-CL for the JVM.
_______________________________________________
Lisp Hug - the mailing list for LispWorks users
lisp-hug@lispworks.com
http://www.lispworks.com/support/lisp-hug.html