- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Scala plug-in for Intellij, XML, and syntax highlighting
Sat, 2009-09-12, 21:29
Hi. I'm using the latest Scala plugin for Intellij 8.1.3. Is there a
known problem with syntax highlighting in code that has inline XML? I
find that if I have inline XML, red error underlines appears in much of
the rest of the code following it. In many cases, I have found that I can
work around it by putting a /* */ comment on the line after the end of the
XML. Is this a known issue, or something I should provide more details
for. What is the best way to report such things - via this list? Thanks
a lot in advance,
Cheers, Tony.
Sorry for the late answer. Yes, XML highlighting in a presence of comments is a bug pin and issue you've mentioned is a known one. Let me describe briefly how things work in Scala plugin for IDEA. In fact, we have three lexer - the first on strips comments, the second one recognizes XML by maintaining an appropriate stack and the last one fetches Scala tokens themselves.
In the way these lexers are implemented now there might be some problems when comments and XML tags stay close. In near-term future we're going to change this design which will allow to avoid such a nasty errors.
Sorry for the inconvenience.
With best regards,
Ilya Sergey
2009/9/12 Anthony B. Coates (Londata) <abcoates@londata.com>