Parenthesis in macro arguments

0 votes
asked Feb 7 in Bug by Andreas Kågedal

The three signals below should look the same, but they don't. The first version, where there are no citations around the third argument, the 'data(addr-inf)' is not rendered correctly.

!definelong CALL(from,to,message)
from -> to : message
!enddefinelong

CALL(SysService, SMW, mysignal(data(addr-inf), a))
CALL(SysService, SMW, "mysignal(data(addr-inf), a)")
SysService -> SMW : mysignal(data(addr-inf), a)
image
commented Feb 14 by Andreas Kågedal
Bump.
Is this a bug?
the arguments

  data(addr-inf), a

are renderd as

  data(addr-inf, a)

I realize you have lots of things to do, and maybe this is not at the top of your list. But just having a ack that you agree that this needs to be fixed at some point would be great.

1 Answer

0 votes
answered Feb 18 by Anthony-Gaudino (7,610 points)
The first looks wrong, it's like you're trying to pass 4 arguments to a macro that only accepts 3.

Also if you use parenthesis on macros they must be quoted.

This example works:

http://www.plantuml.com/plantuml/uml/bS-n2iCW4CRn_PxYugHWNg13IUcQJWwTZtgA41NK5lBsrLB8rA7hn_tWVqjjLDepRZ1PTY7nbfF7wsLTfIivwfPrv5h9iu8nu7p6bl64tnKcJlQG01zgzcgulCA3DPhRNQE8Umq-qIOjDP9aRPb3SaeeZQJ-H8C81SVzYEfYLFqMiFJI_kWR
commented Feb 27 by andreas.kagedal (130 points)
OK, I understand. The macro-mechanism does note handle parenthesis in arugments in any "intelligent" way. They are just another character.
...