Uploaded image for project: 'HPCC'
  1. HPCC
  2. HPCC-20084

Compiler needs to check for three periods used in string slicing

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 6.4.20
    • Fix Version/s: 7.0.0
    • Component/s: eclcc
    • Labels:
      None
    • Environment:
      Windows

      Description

      Docs say: "Substrings may be extracted by using two periods to separate the beginning and ending element numbers within the square brackets to specify the substring (string slice) to extract."

      Currently the compiler will throw an error if one period is used instead of two, but the use of three periods is not checked and incorrect results can be returned.

      Example:

      STRING8 Birthdate := '20180712';

      OUTPUT(Birthdate[1...4]); //returns ''

       

        Attachments

          Activity

            People

            • Assignee:
              richardkchapman Richard Chapman
              Reporter:
              bobf2000 Bob Foreman
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: