location of filter engine in src

Charlton Purvis cplist at EARTHLINK.NET
Mon Jan 30 21:50:59 PST 2006


Thanks, Steve.  Talk about a needle in a haystack.

> So you want to add a modulus operator correct? (I thought it existed but I
> was wrong) To do that is pretty straight forward you have to edit one file
> and recompile:
> 
>   - mapparser.y -> this is the Bison/YACC parser grammar, the '%' operator


> %left '*' '/' '%'

Right.

> and change:
> 
> | math_exp '*' math_exp { $$ = $1 * $3; }
> 
> to
> 
> | math_exp '*' math_exp { $$ = $1 * $3; }
> | math_exp '%' math_exp { $$ = $1 % $3; }

Almost.

| math_exp '%' math_exp   { $$ = (int)$1 % (int)$3; }

Did the trick.

Thanks!

Charlton



More information about the MapServer-users mailing list