In should support empty literal arrays

    • Type: New Feature
    • Resolution: Fixed
    • Priority: Major
    • V4.02
    • Affects Version/s: V4.01_OS
    • Component/s: ABNF
    • None
    • Environment:

      [Proposed]

    • Hide

      Update listExpr in ABNF:

      listExpr = OPEN BWS [primitiveLiteral BWS *( COMMA BWS primitiveLiteral BWS )] CLOSE

      Call out that this evaluates to false.
      Be clear that this was added in 4.02.

      Show
      Update listExpr in ABNF: listExpr = OPEN BWS [primitiveLiteral BWS *( COMMA BWS primitiveLiteral BWS )] CLOSE Call out that this evaluates to false. Be clear that this was added in 4.02.

      [ABNF] defines the inexpr as:

      inExpr = RWS "in" RWS ( listExpr / commonExpr )

      where listExpr is defined as:

      listExpr = OPEN BWS primitiveLiteral BWS *( COMMA BWS primitiveLiteral BWS ) CLOSE

      meaning, the list must have at least one primitive literal.

      Client code generating the expression may well write the open paren, loop through the elements of the array writing each into the expression, then write a close paren. If the array is empty, this will result in an empty listExpr.

      Any reason not to allow an empty listExpr and force the client code above to handle this as a special case?

            Assignee:
            Michael Pizzo (Inactive)
            Reporter:
            Michael Pizzo (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: