CiType ParseType()
{
string baseName = ParseId();
CiType baseType;
if (Eat(CiToken.LeftParenthesis)) {
if (baseName == "string") {
baseType = new CiStringStorageType { LengthExpr = ParseExpr() };
Expect(CiToken.RightParenthesis);
}
else {
Expect(CiToken.RightParenthesis);
baseType = new CiClassStorageType { Name = baseName, Class = new CiUnknownClass { Name = baseName } };
}
}
else
baseType = LookupType(baseName);
return ParseArrayType(baseType);
}