Boo.Lang.Parser.BooParserBase.attributes C# (CSharp) Method

attributes() protected method

protected attributes ( ) : void
return void
        protected void attributes()
        {
            AstAttribute attr = null;

            try {      // for error handling
            if (0==inputState.guessing)
            {
                _attributes.Clear();
            }
            {    // ( ... )*
                for (;;)
                {
                    if ((LA(1)==LBRACK))
                    {
                        match(LBRACK);
                        {
                            switch ( LA(1) )
                            {
                            case THEN:
                            case TRANSIENT:
                            case ID:
                            {
                                attr=attribute();
                                if (0==inputState.guessing)
                                {
                                    if (attr != null) _attributes.Add(attr);
                                }
                                {    // ( ... )*
                                    for (;;)
                                    {
                                        if ((LA(1)==COMMA))
                                        {
                                            match(COMMA);
                                            attr=attribute();
                                            if (0==inputState.guessing)
                                            {
                                                if (attr != null) _attributes.Add(attr);
                                            }
                                        }
                                        else
                                        {
                                            goto _loop55_breakloop;
                                        }

                                    }
            _loop55_breakloop:									;
                                }    // ( ... )*
                                break;
                            }
                            case RBRACK:
                            {
                                break;
                            }
                            default:
                            {
                                throw new NoViableAltException(LT(1), getFilename());
                            }
                             }
                        }
                        match(RBRACK);
                        {
                            switch ( LA(1) )
                            {
                            case EOL:
                            case EOS:
                            {
                                eos();
                                break;
                            }
                            case ABSTRACT:
                            case AS:
                            case CALLABLE:
                            case CLASS:
                            case DEF:
                            case ENUM:
                            case EVENT:
                            case FINAL:
                            case GET:
                            case INTERFACE:
                            case INTERNAL:
                            case NEW:
                            case OVERRIDE:
                            case PARTIAL:
                            case PUBLIC:
                            case PROTECTED:
                            case PRIVATE:
                            case REF:
                            case SET:
                            case SELF:
                            case STATIC:
                            case STRUCT:
                            case THEN:
                            case TRANSIENT:
                            case VIRTUAL:
                            case ID:
                            case MULTIPLY:
                            case LBRACK:
                            case SPLICE_BEGIN:
                            case COLON:
                            {
                                break;
                            }
                            default:
                            {
                                throw new NoViableAltException(LT(1), getFilename());
                            }
                             }
                        }
                    }
                    else
                    {
                        goto _loop57_breakloop;
                    }

                }
            _loop57_breakloop:				;
            }    // ( ... )*
            }
            catch (RecognitionException ex)
            {
            if (0 == inputState.guessing)
            {
                reportError(ex, "attributes");
                recover(ex,tokenSet_30_);
            }
            else
            {
                throw ex;
            }
            }
        }
BooParserBase