Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-8253

Result of macro changed by blank line

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 6.06/04
    • Fix Version/s: 6.08/00
    • Component/s: Cling
    • Labels:
      None
    • Environment:

      CentOS Linux release 7.2.1511 (Core)

      Description

      The anonymous in macroA.C declares an integer to be 1 then calls an anonymous in macroB.C, which sets the integer to be 2. Then it writes the result.

      In this case, the result is 1. So apparently, the change within macroB is local within the anonymous macro (i.e. not the same as root 5).

      However, removing the blank line in macroA.C (i.e. the second line), changes the result to 2. So in this case, we get the same result as for root 5.

      Adding or removing a blank line should not change the result of code.

        Attachments

        1. macroA.C
          0.1 kB
        2. macroB.C
          0.0 kB

          Activity

            People

            Assignee:
            axel Axel Naumann
            Reporter:
            nwarr Nigel Victor Warr
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: