Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 149392 - EL Validator doesn't understand Java Map lookup syntax
Summary: EL Validator doesn't understand Java Map lookup syntax
Status: RESOLVED DUPLICATE of bug 136795
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: jst.jsp (show other bugs)
Version: 1.5   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Ian Tewksbury CLA
QA Contact: David Williams CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-01 23:34 EDT by Darryl Miles CLA
Modified: 2009-06-15 10:36 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Darryl Miles CLA 2006-07-01 23:34:32 EDT
Paste this info a JSP page:

${pageContext.request['javax.servlet.error.exception']}

After the validator runs I get warning markers under 2 characters.

 * The first apostrophe '
 * The second closing square bracket ]


Maybe this was a new feature of EL in a later Servlet spec than WTP supports ?
Comment 1 Nitin Dahyabhai CLA 2006-07-18 03:01:03 EDT
Walter, could this be from a newer EL revision?

Darryl, what are the messages for the two warnings you're seeing?
Comment 2 Darryl Miles CLA 2006-07-18 08:13:51 EDT
Its a single "EL Syntax Error" in the hover over the marker in the margin.  Even through there are two orange underlined characters.

Strangely the following line in JSP:

URI: <a href="${pageContext.request['javax.servlet.error.request_uri']}">${pageContext.request['javax.servlet.error.request_uri']}</a><br/>

Yeilds only the second ${pageContext.....} with two orange underlined characters.  The one in the href="" looks for all intents and purposed valid, with no underlined characters.
Comment 3 Darryl Miles CLA 2006-07-18 08:14:50 EDT
Its a single "EL Syntax Error" in the hover over the marker in the margin.  Even through there are two orange underlined characters.

Strangely the following line in JSP:

URI: <a href="${pageContext.request['javax.servlet.error.request_uri']}">${pageContext.request['javax.servlet.error.request_uri']}</a><br/>

Yeilds only the second ${pageContext.....} with two orange underlined characters.  The one in the href="" looks for all intents and purposes valid, with no underlined characters.


The JSP page in question is setup as an error-page in web.xml:

<error-page>
	<exception-type>java.lang.Throwable</exception-type>
	<location>/WEB-INF/template/exception/ServletException.jsp</location>
</error-page>
Comment 4 Darryl Miles CLA 2008-07-06 22:17:08 EDT
This problem is still true for WTP 3.0.
Comment 5 Darryl Miles CLA 2008-07-07 00:19:44 EDT
Maybe it would be helpful if those commiters that own/maintain the relevant module could summarize where in the Eclipse codebase a 3rd party might look to drill down on the EL validation code that would address a problem like this.

This comment would be true of many bug reports.  You may know where to look but don't have the time to investigate.
Comment 6 Nitin Dahyabhai CLA 2008-07-08 07:48:07 EDT
The relevant interface is org.eclipse.jst.jsp.core.jspel.IJSPELTranslator, with its implementor being what's used by the JSP Translator to create Java source for the JSP file.  The EL translator isn't varying the source it creates based on the project's source level, generating 1.4 syntax even when 1.5 syntax should be used.

The EL supporting code was donated to the existing team who have not really had the time, as you point out, to investigate it.  Due to circumstances beyond our control, the persons expected to own that functionality and maintain it are no longer able to do so.

Any help you could give would be appreciated, and not just by committers, I'm sure.
Comment 7 Nitin Dahyabhai CLA 2008-07-08 07:48:54 EDT
The relevant interface is org.eclipse.jst.jsp.core.jspel.IJSPELTranslator, with its implementor being what's used by the JSP Translator to create Java source for the JSP file.  The EL translator isn't varying the source it creates based on the project's source level, generating 1.4 syntax even when 1.5 syntax should be used.

The EL supporting code was donated to the existing team who have not really had the time, as you point out, to investigate it.  Due to circumstances beyond our control, the persons expected to own that functionality and maintain it are no longer able to do so.

Any help you could give would be appreciated, and not just by committers, I'm sure.
Comment 8 Nitin Dahyabhai CLA 2008-07-08 07:49:08 EDT
The relevant interface is org.eclipse.jst.jsp.core.jspel.IJSPELTranslator, with its implementor being what's used by the JSP Translator to create Java source for the JSP file.  The EL translator isn't varying the source it creates based on the project's source level, generating 1.4 syntax even when 1.5 syntax should be used.

The EL supporting code was donated to the existing team who have not really had the time, as you point out, to investigate it.  Due to circumstances beyond our control, the persons expected to own that functionality and maintain it are no longer able to do so.

Any help you could give would be appreciated, and not just by committers, I'm sure.
Comment 9 Taro App CLA 2008-12-12 02:56:12 EST
Looks like this has been fixed in WTP 3.0.3. (See bug#136795)
Comment 10 Ian Tewksbury CLA 2009-06-15 10:36:34 EDT

*** This bug has been marked as a duplicate of bug 136795 ***