Uploaded image for project: 'CFEngine Community'
  1. CFEngine Community
  2. CFE-1474

Parsing of arrays of lists

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.6.2
    • Component/s: Parsing
    • Labels:
      None
    • Platform:
      Any
    • Found in version (details):
      Master

      Description

      vars:

      "one[myuqhostname]" slist =>

      { "one", "two" }

      ;
      "two" slist =>

      { "three", "four" }

      ;

      "three" slist =>

      { @(one[$(sys.uqhost)]), @(two) }

      ;
      ^^^^^^^^

      This will fail to parse, due to missing symbols

      Fix is to modify libpromises/cf3lex.l to add $()

      nakedvar [$@][(][a-zA-Z0-9_$()[]\200-\377.:]+[)]|[$@][

      {][a-zA-Z0-9_$()\[\]\200-\377.:]+[}

      ]

      and cf3.defs.h

      #define CF_NAKEDLRANGE "@[(][a-zA-Z0-9_$(){}\\[
      ].:]+[)]"

      See my private branch commits, https://github.com/markburgess/core/commits/master

      517a7e2b74c82d6db5966cb89fd57d4a37534401
      7512387b4e2bb9aaf1039578bb87883be56fed09

        Attachments

          Activity

            People

            • Assignee:
              a10004 Mark Burgess (Inactive)
              Reporter:
              a10004 Mark Burgess (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Summary Panel