public override void ExitNamedType(ExpressParser.NamedTypeContext context) { string t = null; if (context.typeRef() != null) { t = context.typeRef().SimpleId().GetText(); } else if (context.entityRef() != null) { t = context.entityRef().SimpleId().GetText(); } if (currTypeData is SimpleType) { ((SimpleType)currTypeData).WrappedType = t; } else if (currTypeData is Entity) { foreach (var ad in currAttrDatas) { ad.Type = t; } } }
private string ParseNamedType(ExpressParser.NamedTypeContext context) { if (context.typeRef() != null) { return(context.typeRef().SimpleId().GetText()); } else if (context.entityRef() != null) { return(context.entityRef().SimpleId().GetText()); } return(null); }