[Mono-devel-list] PATCH: EvaluateRelational for Mono JScript.NET

César López Natarén cnataren at novell.com
Sun Feb 13 18:31:32 EST 2005

On Sun, 2005-02-13 at 07:59 -0400, Rogerio Pereira wrote: 
> Hi,

Hello Rogerio. 

Thanks for the patch, it goes through the correct path but I have some

> switch (op) {
>     case JSToken.GreaterThan:
>     ....
>     case JSToken.LessThan:
> ...
> switch (op) {
> case JSToken.GreaterThan:

You can avoid duplicating the checks for the operator in each pair of
code's combination, if you put the switch of the op the most global
level, and inside it you check the type code of the operands, also you
can put those checks inside another function and use it where is needed.

Different .NET numeric types get grouped and other types get converted
to numeric types.

Take a look at this two places for completing the patch:


section 11.4.



More information about the Mono-devel-list mailing list