Macro entries cannot include "$(" as a literal
The bug
Macro entries, which start with $ in an mcfunction file, cannot include $( as a literal because they are attempted to be parsed as parameters, not as literal segments.
Workaround
You can workaround this by instantiating a macro with the argument $(.
macro.mcfunction
$say $(a)
When you run the following command,
function macro {a: "$("}
$say $(a) will become say $( after instantiation.
2023-08-23, 05:14 PM
2023-08-24, 07:03 AM
2023-08-24, 07:03 AM
1
3
-