Mercurial > hg-old > index.cgi
changeset 165:566943f98f8d
Made pragma actually take multiple pragmas on one line
author | lost |
---|---|
date | Sat, 31 Jan 2009 18:22:02 +0000 |
parents | 586069fb17a1 |
children | 178995c346d9 |
files | lwasm/pragma.c |
diffstat | 1 files changed, 10 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/lwasm/pragma.c Sat Jan 31 18:12:33 2009 +0000 +++ b/lwasm/pragma.c Sat Jan 31 18:22:02 2009 +0000 @@ -63,14 +63,16 @@ while (isspace(**optr)) (*optr)++; - - while (c < 127 && **optr && !isspace(**optr)) + +pragmaagain: + c = 0; + while (c < 127 && **optr && **optr != ',' && !isspace(**optr)) { pragma[c++] = **optr; (*optr)++; } - if (c == 0 || (**optr && !isspace(**optr))) + if (c == 0 || (**optr && **optr != ',' && !isspace(**optr))) { if (error) { @@ -118,6 +120,11 @@ } } } + if (**optr == ',') + { + (*optr)++; + goto pragmaagain; + } } OPFUNC(pseudo_pragma)