JSP's showing errors in editor and failing Jasper due to includes

Hi guys, I just started a new job up in NYC and the shop I'm with uses JSP's extensively (I am pretty unfamiliar with them as I used velocity extensively before). The question I have is that their JSP's routinely do stuff like this..

<% String aString = "that"; %> <%@include file="included.jsp"%> included.jsp <% aString.equals("that"); //IDEA editor highlights error here as 'aString' hasn't been declared %>]]>

The result of this sort of thing is that I can't run jasper validator before I deploy and my jsp's are all highlighted in red, even though ultimately the pages work when I deploy to tomcat.

So I'm wondering...Is this a fact of life with JSP editing? Is this way of including jsp's a bad practice? Any suggestions?




The 6.0 version solves the problem. Take a look at EAP.