Menu

#63 x/=y doesn't work

All_releases
closed-fixed
5
2004-09-27
2004-09-27
Jos Hirth
No

Happens with: 2.0.8 and 2.0.10

"+=", "-=" and "*=" work as they should.

However, "/=" causes it to bomb with:
net.janino.util.TunnelException caused by:
net.janino.Parser$ParseException: File Something.java,
Line X, Column X: Unexpected token "=" in primary

Test cases:

ScriptDemo -s "int x=4;x*=2;" -rt "void" -pn "" -pt ""
[works]

ScriptDemo -s "int x=4;x/=2;" -rt "void" -pn "" -pt ""
[doesn't work]

Workaround:
Write x=x/y instead :P

Discussion

  • Arno Unkrig

    Arno Unkrig - 2004-09-27
    • status: open --> closed
     
  • Arno Unkrig

    Arno Unkrig - 2004-09-27

    Logged In: YES
    user_id=865893

    The scanner didn't detect the "/=" operator while it checked
    for the beginning of a comment ("//" or "/*").
    Released in 2.0.11.

    Thank you for the precise bug report!

     
  • Arno Unkrig

    Arno Unkrig - 2004-09-27
    • status: closed --> closed-fixed
     

Log in to post a comment.

MongoDB Logo MongoDB