Uploaded image for project: 'Velocity'
  1. Velocity
  2. VELOCITY-359

#if(some expression)#end causes ParseException

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.3.1
    • 1.5
    • Engine
    • None
    • Operating System: Windows XP
      Platform: PC
    • 33669

    Description

      #if(...) #end works but #if(...)#end

      Stacktrace:

      org.apache.velocity.exception.ParseErrorException: Encountered "#en
      d\n" at line 61, column 44.
      Was expecting one of:
      "(" ...
      <RPAREN> ...
      <ESCAPE_DIRECTIVE> ...
      <SET_DIRECTIVE> ...
      "\\\\" ...
      "
      " ...
      <TEXT> ...
      <SINGLE_LINE_COMMENT> ...
      "*#" ...
      "*#" ...
      <STRING_LITERAL> ...
      "if" ...
      "stop" ...
      <NUMBER_LITERAL> ...
      <WORD> ...
      <DOT> ...
      "

      {" ... "}

      " ...
      <IDENTIFIER> ...

      If you wonder why we write such stupid statements: We use velocity inside a CMS
      where it is possible to leave texts blank inside an #if-block.

      Attachments

        Activity

          People

            Unassigned Unassigned
            antarapero@gmx.de Peter Romianowski
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: