Mercurial > projects > dil
diff trunk/src/Parser.d @ 104:b535016f8c3f
- DeclaratorSuffix must be parsed after an Identifier.
author | aziz |
---|---|
date | Sun, 08 Jul 2007 11:03:05 +0000 |
parents | 511a1aa25896 |
children | df34ec47fb81 |
line wrap: on
line diff
--- a/trunk/src/Parser.d Sun Jul 08 10:14:00 2007 +0000 +++ b/trunk/src/Parser.d Sun Jul 08 11:03:05 2007 +0000 @@ -817,7 +817,7 @@ Type parseType() { - return parseDeclaratorSuffix(parseBasicType2(parseBasicType())); + return parseBasicType2(parseBasicType()); } Type parseBasicType() @@ -946,17 +946,18 @@ Type parseDeclarator(ref string ident, bool identOptional = false) { - auto t = parseBasicType2(parseBasicType()); + auto t = parseType(); if (token.type == T.Identifier) { ident = token.srcText; nT(); + t = parseDeclaratorSuffix(t); } else if (!identOptional) errorIfNot(T.Identifier); - return parseDeclaratorSuffix(t); + return t; } Argument[] parseParameters()