#80 Macro expansion broken when arguments intersect parameters

v5.2
closed-fixed
Mike Kinghan
None
3
2014-08-31
2013-10-26
Mike Kinghan
No

If a function-like macro is called with arguments some of which shadow formal parameters then the expansion can lose the shadowing argument and substitute another.

E.g. if FOO(T1,T2) is called with (T2,T3) then replacement of T1 with T2 at first yields FOO(T2,T2); then replacement of T2 with T3 yields FOO(T3,T3).

To fix this replaced segments must be noted and not replaced again.

Discussion

  • Mike Kinghan
    Mike Kinghan
    2013-11-03

    • assigned_to: Mike Kinghan
     
  • Mike Kinghan
    Mike Kinghan
    2014-08-31

    Closed in v6.0

     
  • Mike Kinghan
    Mike Kinghan
    2014-08-31

    • status: open --> closed-fixed