Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-489

Handle += / -= with consistent semantics

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • PUP 3.5.0
    • Compiler
    • None

    Description

      The current 4x implementation does this:

      • if referenced and given are numeric, do arithmetic + or -
      • if referenced and given are collections, do concat/merge
      • else fail (no string concatenation)

      Decide:

      • is this implementation ok
      • should string concatenation be allowed (+ is not string concat elsewhere)
      • Remove in favor of explicit $a = $a + [ ] (etc. possible because hashes and arrays support + operator).

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              henrik.lindberg Henrik Lindberg
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support