3

I'm using Eclipse 3.5 with the FreeMarker template plugin, and it's showing me a syntax validation problem that I don't care to see.

How do I turn this validation off, or possibly downgrade this template error to a warning? In previous versions of Eclipse, I'd probably look under Window -> Preferences -> Validation, but I don't see that in 3.5.

UPDATE: For the record, the error I'm getting is this:

Error in template: foo.ftl on line 16, column 9 noescape with no matching escape encountered. in foo.ftl

Jeff
  • 14,831
  • 15
  • 49
  • 59

2 Answers2

1

As far as I know, the Freemarker plugin (assuming you use the one from JBoss Tools) shows syntax errors and those ones - just like java syntax errors in the java editor - cannot turn off or "downgrade". Basically it means that the Freemarker parser cannot parse your template.

Window / Preferences / Validation are not in the "core" Eclipse, you need to install the web tools to get the Validation page. However, you cannot set Freemarker syntax validation options there.

Csaba_H
  • 8,215
  • 1
  • 41
  • 42
  • Not what I was hoping to hear, but I fear you may be correct. This is pretty much worse than not having an Eclipse plugin at all. One question: my plugin is from Visigoth Software Society, not JBoss Tools. If you know of any differences there, please let me know. – Jeff Oct 14 '09 at 17:14
  • I tried the Visigoth plugin and I cannot see any difference on the subject. Both plugins use the Freemarker syntax checker and neither of them allow to turn this feature off. Just out of curiosity what is your use case for having such error in your Freemarker script? – Csaba_H Oct 15 '09 at 18:21
1

I had a similar syntax error issue and kept getting the red X mark on my freemarker template file. The solution was to replace the old freemarker.jar which did not support the new syntax... in my case it was in ...eclipse\plugins\org.visigoths.freemarker_2.3.2

After restarting eclipse, I had to open the .ftl file once so that it would be re-validated and the syntax error disappeared.

  • That didn't seem to work for me, but thanks for the suggestion. – Jeff Jan 08 '10 at 16:59
  • My plugin installation has already the latest freemarker version. Never the less, the `noescape` tag is marked as error. IMHO this is a bug, since the template works exactly as expected. – BetaRide Jun 18 '15 at 11:38