Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    UDL (User-defined language) request 4: variable string matching (HEREDOC)

    General Discussion
    1
    1
    1070
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Mikhail Nikitin
      Mikhail Nikitin last edited by

      How to emphasize a HEREDOC syntax?

      For those unaware of this term, it is a way to wrap long lines. The first line should end with <<Name, where Name is any string, then some lines follow, and the last line shall be Name. The first Name can be highlighted with “prefix” syntax. The trick here is to highlight the second Name.

      Example

      ADD( <<END
      1, 
      2
      )
      END
      

      is equivalent to

      ADD(1, 2)
      

      See also https://en.wikipedia.org/wiki/Here_document

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright © 2014 NodeBB Forums | Contributors