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

Escaping of directives does not work if the directive is in curly brackets

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.5
    • 1.6
    • Engine
    • None

    Description

      To escape a directive, one must precede it with an escape backslash. According to the documentation:
      #if ($foo)
      \$bar
      #end
      Should render as
      #if $foo)
      $bar
      #end
      And it does.
      However, if you enclose the directive in curly brackets, the escape is ignored:
      #

      {if}

      ($foo)
      \$bar
      #

      {end}

      Ignores the escape and evaluates to
      \
      (assuming $foo is false).

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            veliashberg Alik
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment