* fixes #12741
* updated tests
This commit is contained in:
Andreas Rumpf 2020-04-19 11:59:01 +02:00 • committed by GitHub
commit 73eff1f457
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 55 additions and 47 deletions

View file

@ -1476,9 +1476,9 @@ proc semProcAnnotation(c: PContext, prc: PNode;
let ident = considerQuotedIdent(c, key)
if strTableGet(c.userPragmas, ident) != nil:
continue # User defined pragma
else:
else:
let sym = searchInScopes(c, ident)
if sym != nil and sfCustomPragma in sym.flags:
if sym != nil and sfCustomPragma in sym.flags:
continue # User custom pragma
# we transform ``proc p {.m, rest.}`` into ``m(do: proc p {.rest.})`` and