Fix getCustomPragmaVal for some multi arg pragmas (#17723)
* Fix getCustomPragmaVal for some multi arg pragmas * Bootstrap fix
This commit is contained in:
parent
f8dce493d3
commit
51a40c1f38
2 changed files with 54 additions and 41 deletions
|
|
@ -396,3 +396,12 @@ block:
|
|||
newLit(hasAttr)
|
||||
|
||||
doAssert hasMyAttr(TObj)
|
||||
|
||||
# misc
|
||||
{.pragma: haha.}
|
||||
{.pragma: hoho.}
|
||||
template hehe(key, val: string, haha) {.pragma.}
|
||||
|
||||
type A {.haha, hoho, haha, hehe("hi", "hu", "he").} = int
|
||||
|
||||
assert A.getCustomPragmaVal(hehe) == (key: "hi", val: "hu", haha: "he")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue