diff options
Diffstat (limited to 'gcc/d/dmd/parse.d')
-rw-r--r-- | gcc/d/dmd/parse.d | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/d/dmd/parse.d b/gcc/d/dmd/parse.d index ed85a5d..6fb542f 100644 --- a/gcc/d/dmd/parse.d +++ b/gcc/d/dmd/parse.d @@ -888,6 +888,7 @@ class Parser(AST, Lexer = dmd.lexer.Lexer) : Lexer error("redundant visibility attribute `%s`", AST.visibilityToChars(prot)); } pAttrs.visibility.kind = prot; + const attrloc = token.loc; nextToken(); @@ -908,7 +909,6 @@ class Parser(AST, Lexer = dmd.lexer.Lexer) : Lexer } } - const attrloc = token.loc; a = parseBlock(pLastDecl, pAttrs); if (pAttrs.visibility.kind != AST.Visibility.Kind.undefined) { @@ -3168,9 +3168,7 @@ class Parser(AST, Lexer = dmd.lexer.Lexer) : Lexer if (udas) { - auto s = new AST.Dsymbols(); - s.push(em); - auto uad = new AST.UserAttributeDeclaration(udas, s); + auto uad = new AST.UserAttributeDeclaration(udas, new AST.Dsymbols()); em.userAttribDecl = uad; } |