Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/edje
Dir : e17/libs/edje/src/bin
Modified Files:
edje_cc_out.c
Log Message:
aaaaaaah #'s form cpp in embryo verbatim snippets - strip them.
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/bin/edje_cc_out.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- edje_cc_out.c 25 Apr 2004 04:24:56 -0000 1.17
+++ edje_cc_out.c 28 Apr 2004 03:31:06 -0000 1.18
@@ -440,7 +440,24 @@
fprintf(f, " \n");
ln++;
}
- fprintf(f, "%s\n", cd->shared);
+ {
+ char *sp;
+ int hash = 0;
+ int newlined = 0;
+
+ for (sp = cd->shared; *sp; sp++)
+ {
+ if ((sp[0] == '#') && (newlined))
+ {
+ hash = 1;
+ }
+ newlined = 0;
+ if (sp[0] == '\n') newlined = 1;
+ if (!hash) fputc(sp[0], f);
+ else if (sp[0] == '\n') hash = 0;
+ }
+ fputc('\n', f);
+ }
ln += cd->l2 - cd->l1 + 1;
}
for (ll = cd->programs; ll; ll = ll->next)
@@ -458,7 +475,23 @@
/* FIXME: this prototype needs to be */
/* formalised and set in stone */
fprintf(f, "public _p%i(sig[], src[]) {", cp->id);
- fprintf(f, "%s", cp->script);
+ {
+ char *sp;
+ int hash = 0;
+ int newlined = 0;
+
+ for (sp = cp->script; *sp; sp++)
+ {
+ if ((sp[0] == '#') && (newlined))
+ {
+ hash = 1;
+ }
+ newlined = 0;
+ if (sp[0] == '\n') newlined = 1;
+ if (!hash) fputc(sp[0], f);
+ else if (sp[0] == '\n') hash = 0;
+ }
+ }
fprintf(f, "}");
ln += cp->l2 - cp->l1 + 1;
}
-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g.
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs