Note that there are some explanatory texts on larger screens.

plurals
  1. POJSP EL (Expression Language) causing problems in Eclipse
    primarykey
    data
    text
    <p>My system: Ubuntu 9.10. Eclipse 3.5.1 with Java EE 1.2.1 (manual install - NOT from synaptic). Web Developer Tools 3.1.1</p> <p>I've recently adopted someone else's code (a Dynamic Web Project), and run into lots of errors, warnings and incorrect syntax highlighting in Eclipse. I've narrowed it down to these 4 lines of code (create a new Dynamic Web Project, and then a new JSP page, and put this in the body):</p> <pre><code>${(1&lt;2)? "" : "no"} &lt;%for (int i = 0; i &lt; 5; i++) {%&gt; &lt;div&gt;${5}&lt;/div&gt; &lt;%}%&gt; </code></pre> <p><strong>Errors / Warnings / Incorrect syntax highlighting</strong></p> <blockquote> <p>line1: yellow warning line under '&lt;': Invalid character used in text string (${(1&lt;2)? "yes" : "no"}).</p> <p>line2: red error line under 'f': Multiple annotations found at this line: 1) Syntax error, insert "Finally" to complete TryStatement. 2) Syntax error, insert "}" to complete ClassBody</p> <p>line2: red error line under ')': Syntax error on token ")", try expected after this token</p> <p>line3: yellow warning line under 'div': No end tag (/div).</p> <p>line3: yellow warning line under '&lt;' of closing div: Multiple annotations found at this line: 1) Invalid character used in text string (${5} &lt;%}%>). 2) Invalid character used in text string (${5} &lt;%}%>).</p> <p>line3: '/div' is black and purple (for scriptlet code?) instead of green for HTML code</p> <p>line4: The opening and closing scriplet tags '&lt;%' and '%>' are black instead of orange</p> </blockquote> <p>The page works as expected in a browser: you get '5' five times. If you change the empty quotes on line 1 to "yes" then save, close the file in the editor, r click it in the project explorer > validate, then re-open it: all errors / warnings / incorrect syntax highlighting disappear, except the first one (invalid character). This is incredibly irritating. Any thoughts would be greatly appreciated.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload