Using my suggestedCan we rewrite REPEAT (preferrably with an existing simulator, or at least in a way that *might* be next-spec compliant) so that this will work: `REPEAT(`FUNC(n), d) Or this `REPEAT(`REPEAT(n,foo), d)
`define
of REPEAT,
`REPEAT(`REPEAT(n,foo), d )
`REPEAT_`REPEAT_n(foo)(d)
^^^^^^^^
Error: ./svpp4.sv:18: The macro 'REPEAT_' has not been defined.
(VER-913)
For this reason, I think it was a mistake to passxpand the actual argument macro invocation at the point when it is used in a formal substitution.Yes, I think that's the right track.
`REPEAT_
as a macro actual argument.`CONCAT(REPEAT_,n)
to form the identifier,
but you don't want to`define REPEAT( n, d ) ` ` CONCAT ( REPEAT_ , n ) ( d ) // not
universally supported
`define REPEAT( n, d ) `REPEAT_``n(d)
This archive was generated by hypermail 2.1.8 : Wed Jun 23 2010 - 09:52:03 PDT