Ticket #48 (closed bug: fixed)
py2js parentheses bug
| Reported by: | Hemml | Owned by: | apoirier |
|---|---|---|---|
| Priority: | critical | Component: | uncategorized |
| Version: | Keywords: | py2js | |
| Cc: |
Description
in if-statements some parentheses can be lost.
This code:
if a==b or (c==d and d==e):
alert("QQ")
translates to:
| (c == d) && (d == e)) { |
alert("QQ");
}
but must be translated to:
| ((c == d) && (d == e))) { |
alert("QQ");
}
Change History
Note: See
TracTickets for help on using
tickets.
(In [5bced6e5760a46904dc6a4595455069c3e4e9d10]) Fixes #48.
Boolean expressions parenthesis handling backported from the lastest version of pyjs.