Closed Tharit closed 8 years ago
cc @wbond
This no longer occurs with the latest version at https://github.com/sublimehq/Packages. Please note the version there has not yet been shipped with a version of Sublime Text and will have some bugs until the next dev build of ST is out.
This was fixed a while ago and is part of the recent dev builds.
It seems like the syntax highlighting somehow looses the context of the ternary operator when a binary operator is used in the "if true" part. The last operand in the binary operator is then highlighted as if it was an object property (because of the following colon). This can be "fixed" by wrapping the binary operand in parenthesis.
Example:
Expected behaviour: "b" should never be highlighted as if it was a property.