Syntax highlighting not always working for `while`
The first `while` is not correctly detected. It has a different color. The second `while` as all the other keywords is correctly colored.
object X {
while (true) {}
do {} while (true)
}
Leave a comment
on 2013-01-07 05:42 *
By huitseeker
Eclipse version changed from Indigo to Indigo - Eclipse 3.7
Component changed from Semantic Highlight to Syntax Highlighting
Summary changed from semantic highlighting not always working for `while` to Syntax highlighting not always working for `while`
on 2013-01-25 05:33 *
By Simon Schäfer
(In scala-ide:d5a865f071873d014ce299042041f9bc327c4793) Correct syntax highlighting for while-keyword
While syntax highlighting correctly recognizes the while-keyword as a
keyword, semantic highlighting treats it as a method. Because semantic
highlighting is activated after its syntax counterpart, it overwrites
the previous detected colors.
The new behavior omits all occurrences of LabelDef in the AST because
they don't regularly appear in Scala sources but represent while- and
do-while-keywords internally in the compiler. Hence they must not be
highlighted.
Fix #1000984
Branch: master
While syntax highlighting correctly recognizes the while-keyword as a
keyword, semantic highlighting treats it as a method. Because semantic
highlighting is activated after its syntax counterpart, it overwrites
the previous detected colors.
The new behavior omits all occurrences of LabelDef in the AST because
they don't regularly appear in Scala sources but represent while- and
do-while-keywords internally in the compiler. Hence they must not be
highlighted.
Fix #1000984
Branch: master
(In scala-ide:c4786905cb592f487b3a667e9984cbf7ff24bdee) Merge pull request #281 from sschaef/issue/while-highligting-correction
Correct syntax highlighting for while-keyword - Fix #1000984
Branch: master
Correct syntax highlighting for while-keyword - Fix #1000984
Branch: master