[Ecls-list] API prefix (ecl_) and ffi:c-lines
ehuels at gmail.com
Mon Jul 23 07:31:13 UTC 2007
Some months ago, the full (?) ecl api has received an ecl_ prefix
(apart from all functions which were already cl_ prefixed).
When writing FFI code with c-lines and c-inline, a developer may need
these ecl_ functions. Currently, there's no way to query which API a
file is being compiled on.
I propose to resolve this issue by pushing a new feature into
*FEATURES* at ECL startup: :PREFIXED-API. The patch below does this.
At first I thought I'd try to resolve this with a version number
increase, but then I realised I'd be pushing a feature myself, while
others can benefit from the solution when implemented this way.
Here's a patch to implement my idea:
RCS file: /project/ecl/cvsroot/ecl/src/c/main.d,v
retrieving revision 1.103
diff -u -r1.103 main.d
--- src/c/main.d 3 Jun 2007 13:56:11 -0000 1.103
+++ src/c/main.d 23 Jul 2007 06:49:28 -0000
@@ -424,11 +424,12 @@
cl_list(8, @'&optional', @'&rest', @'&key',
@'&aux', @'&whole', @'&environment', @'&body'));
- features = cl_list(4,
+ features = cl_list(5,
#define ADD_FEATURE(name) features = CONS(ecl_make_keyword(name),features)
More information about the ecl-devel