I have this .jsp file:
<script language="javascript">
<c:if test="1!=2">
</c:if>
</script>
and I got Syntax Error in Eclipse WTP (STS), and if I have this: <c:if test="1==2">
there is no Syntax Error.
<c:if test="1!=2">
in this file outside <script>..</script>
is ok.
Eclipse often signal syntax errors when there is none, because it fails parsing JSTL inside HTML inside JavaScript (or other combinations) correctly.
Test your code by deploying it on your server and running it. If it runs, then you've encountered an Eclipse bug.