From b194148d0f20d8e38947a40b2673f481cf0e55ce Mon Sep 17 00:00:00 2001 From: xchaos Date: Mon, 28 Jan 2008 08:44:30 +0000 Subject: [PATCH] some work git-svn-id: https://dev.arachne.cz/repos/cll1h/trunk@45 4bb87942-c103-4e5a-b51c-0ebff58f8515 --- cll1.h | 7 +++---- demos/arguments1.c | 4 ++-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/cll1.h b/cll1.h index a12fdff..09195a5 100644 --- a/cll1.h +++ b/cll1.h @@ -20,7 +20,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ - #ifndef _CLL1_H #define _CLL1_H #define CLL1H_VERSION "0.7.1" @@ -89,8 +88,8 @@ #define dictionary(TYPE) tree(TYPE); char *__key #define array(TYPE) tree(TYPE); int __key #define interface(TYPE) struct TYPE *__interface -#define get_mem(...) (struct _ARG1(__VA_ARGS__,)*)_cll1_malloc(sizeof(struct _ARG1(__VA_ARGS__,)), _ARG2(__VA_ARGS__,,) - 0 ) #define get_str(...) (char *)_cll1_get_str(__VA_ARGS__,(void *)&_cll1_get_str) +#define get_mem(...) (struct _ARG1(__VA_ARGS__,)*)_cll1_malloc(sizeof(struct _ARG1(__VA_ARGS__,)), _ARG2(__VA_ARGS__,,) - 0 ) /* .----------------------------------------------------------------------. / 5. C<<1 string manipulation, updated 2008-01-26 xCh. '----------------------------------------------------------------------- */ @@ -188,7 +187,7 @@ #define _FOR_COLUMNS(A,B,C) _NEW_I for(_I=0,prefix(A,B,C);A;((A!=B)&&prefix(A,B,C)||(A=NULL)),_I++) #define _FOR_VALID_COLUMNS(A,B,C) _NEW_I for(_I=0,prefix(A,B,C);A;((A!=B)&&prefix(A,B,C))||(A=NULL)) if(*A&&++_I) /* .----------------------------------------------------------------------. - / 11. C<<1 CGI and FASTCGI handling, updated 2008-01-16 by xCh. + / 11. C<<1 CGI and FASTCGI handling, updated 2008-01-16 by xCh. '----------------------------------------------------------------------- */ #ifdef USE_LIBRARY_FASTCGI #define while_fastcgi_accept while(FCGI_Accept()>=0) @@ -202,7 +201,7 @@ #define _CGIDICT #endif /* .----------------------------------------------------------------------. - / 12. MySQL infrastructure and wrappers - updated 2007-12-19 by xCh. + / 12. MySQL infrastructure and wrappers, updated 2007-12-19 by xCh. '----------------------------------------------------------------------- */ #ifdef USE_LIBRARY_MYSQL #define mysql_connect(S,U,P,D) ((_SQLCatom=get_mem(_SQLCAtom)) && push(_SQLCatom,_SQLCstack) && (_SQLCatom->C=mysql_init(NULL)),(_SQLCatom->C && mysql_real_connect(_SQLCatom->C,S,U,P,D,0,NULL,0)?_SQLCatom->C:NULL)) diff --git a/demos/arguments1.c b/demos/arguments1.c index ae32e11..f863b64 100644 --- a/demos/arguments1.c +++ b/demos/arguments1.c @@ -1,10 +1,10 @@ #include "cll1.h" -//try to run: ./arguments1 -x xxx yyyy -c cccc +/* try to run: ./arguments1 -x xxx yyyy -c cccc */ program { - Define_str(ptr); + define_str(ptr); if_args then { -- 2.30.2