// can be usingDirectives, globalAttribs, or NamespaceMembersDecls
// NamespaceMembersDecls include namespaces, class, struct, interface, enum, delegate
private void parseNamespaceOrTypes() throws FeatureNotSupportedException {
        while (!curtok.equals(EOF)) {
            // todo: account for assembly attributes
            parsePossibleAttributes(true);
            if (curAttributes.size() > 0) {
                for (AttributeNode an : curAttributes) {
                    cu.attributes.add(an);
                }
                curAttributes.clear();
            }
            // can be usingDirectives, globalAttribs, or NamespaceMembersDecls
            // NamespaceMembersDecls include namespaces, class, struct, interface, enum, delegate
            switch (curtok.id) {
                case TokenID.Using:
                    // using directive
                    parseUsingDirectives();
                    break;
                case TokenID.New:
                case TokenID.Public:
                case TokenID.Protected:
                case TokenID.Partial:
                case TokenID.Static:
                case TokenID.Internal:
                case TokenID.Private:
                case TokenID.Abstract:
                case TokenID.Sealed:
                    //parseTypeModifier();
                    curmods |= modMap.get(curtok.id);
                    advance();
                    break;
                case TokenID.Namespace:
                    parseNamespace();
                    break;
                case TokenID.Class:
                    parseClass();
                    break;
                case TokenID.Struct:
                    parseStruct();
                    break;
                case TokenID.Interface:
                    parseInterface();
                    break;
                case TokenID.Enum:
                    parseEnum();
                    break;
                case TokenID.Delegate:
                    parseDelegate();
                    break;
                case TokenID.Semi:
                    advance();
                    break;
                default:
                    return;
            }
        }
    }
curAttributes.clear();
}
// can be usingDirectives, globalAttribs, or NamespaceMembersDecls
// NamespaceMembersDecls include namespaces, class, struct, interface, enum, delegate
switch (curtok.id) {
case TokenID.Using:
private void parseNamespaceOrTypes() throws FeatureNotSupportedException {
while (!curtok.equals(EOF)) {
// todo: account for assembly attributes
parsePossibleAttributes(true);
if (curAttributes.size() > 0) {
for (AttributeNode an : curAttributes) {
cu.attributes.add(an);
}
curAttributes.clear();
}
// can be usingDirectives, globalAttribs, or NamespaceMembersDecls
// NamespaceMembersDecls include namespaces, class, struct, interface, enum, delegate
switch (curtok.id) {
case TokenID.Using:
// using directive
parseUsingDirectives();
break;
case TokenID.New:
case TokenID.Public:
case TokenID.Protected:
case TokenID.Partial:
case TokenID.Static:
private void parseNamespaceOrTypes() throws FeatureNotSupportedException {
while (!curtok.equals(EOF)) {
// todo: account for assembly attributes
parsePossibleAttributes(true);
if (curAttributes.size() > 0) {
for (AttributeNode an : curAttributes) {
cu.attributes.add(an);
}
curAttributes.clear();
}
// can be usingDirectives, globalAttribs, or NamespaceMembersDecls
// NamespaceMembersDecls include namespaces, class, struct, interface, enum, delegate
switch (curtok.id) {
case TokenID.Using:
// using directive
parseUsingDirectives();
break;
case TokenID.New:
case TokenID.Public:
case TokenID.Protected:
case TokenID.Partial:
case TokenID.Static:
case TokenID.Internal:
case TokenID.Private:
case TokenID.Abstract:
case TokenID.Sealed:
//parseTypeModifier();
curmods |= modMap.get(curtok.id);
advance();
break;
case TokenID.Namespace:
parseNamespace();