#!/usr/bin/env ruby # # SfpLang.g # -- # Generated using ANTLR version: 3.2.1-SNAPSHOT Jul 31, 2010 19:34:52 # Ruby runtime library version: 1.8.11 # Input grammar file: SfpLang.g # Generated at: 2013-08-04 06:02:42 # # ~~~> start load path setup this_directory = File.expand_path( File.dirname( __FILE__ ) ) $LOAD_PATH.unshift( this_directory ) unless $LOAD_PATH.include?( this_directory ) antlr_load_failed = proc do load_path = $LOAD_PATH.map { |dir| ' - ' << dir }.join( $/ ) raise LoadError, <<-END.strip! Failed to load the ANTLR3 runtime library (version 1.8.11): Ensure the library has been installed on your system and is available on the load path. If rubygems is available on your system, this can be done with the command: gem install antlr3 Current load path: #{ load_path } END end defined?( ANTLR3 ) or begin # 1: try to load the ruby antlr3 runtime library from the system path require 'antlr3' rescue LoadError # 2: try to load rubygems if it isn't already loaded defined?( Gem ) or begin require 'rubygems' rescue LoadError antlr_load_failed.call end # 3: try to activate the antlr3 gem begin Gem.activate( 'antlr3', '~> 1.8.11' ) rescue Gem::LoadError antlr_load_failed.call end require 'antlr3' end # <~~~ end load path setup module SfpLang # TokenData defines all of the token type integer values # as constants, which will be included in all # ANTLR-generated recognizers. const_defined?( :TokenData ) or TokenData = ANTLR3::TokenScheme.new module TokenData # define the token constants define_tokens( :T__68 => 68, :T__69 => 69, :T__66 => 66, :EXPONENT => 14, :T__67 => 67, :T__64 => 64, :T__29 => 29, :T__65 => 65, :T__28 => 28, :T__62 => 62, :T__27 => 27, :T__63 => 63, :T__26 => 26, :T__25 => 25, :T__24 => 24, :T__23 => 23, :T__22 => 22, :T__21 => 21, :T__20 => 20, :OCTAL_ESC => 17, :ID => 6, :T__61 => 61, :T__60 => 60, :EOF => -1, :T__55 => 55, :T__19 => 19, :T__56 => 56, :T__57 => 57, :T__58 => 58, :ESC_SEQ => 13, :BOOLEAN => 9, :T__51 => 51, :T__52 => 52, :T__18 => 18, :T__53 => 53, :T__54 => 54, :T__59 => 59, :NL => 4, :COMMENT => 11, :T__50 => 50, :T__42 => 42, :T__43 => 43, :T__40 => 40, :T__41 => 41, :T__80 => 80, :T__46 => 46, :T__81 => 81, :T__47 => 47, :T__82 => 82, :T__44 => 44, :T__83 => 83, :T__45 => 45, :T__48 => 48, :T__49 => 49, :UNICODE_ESC => 16, :NULL => 8, :NUMBER => 7, :HEX_DIGIT => 15, :MULTILINE_STRING => 10, :T__84 => 84, :T__30 => 30, :T__31 => 31, :T__32 => 32, :WS => 12, :T__71 => 71, :T__33 => 33, :T__72 => 72, :T__34 => 34, :T__35 => 35, :T__70 => 70, :T__36 => 36, :T__37 => 37, :T__38 => 38, :T__39 => 39, :T__76 => 76, :T__75 => 75, :T__74 => 74, :T__73 => 73, :T__79 => 79, :STRING => 5, :T__78 => 78, :T__77 => 77 ) # register the proper human-readable name or literal value # for each token type # # this is necessary because anonymous tokens, which are # created from literal values in the grammar, do not # have descriptive names register_names( "NL", "STRING", "ID", "NUMBER", "NULL", "BOOLEAN", "MULTILINE_STRING", "COMMENT", "WS", "ESC_SEQ", "EXPONENT", "HEX_DIGIT", "UNICODE_ESC", "OCTAL_ESC", "'include'", "'state'", "'{'", "'}'", "'composite'", "'class'", "'schema'", "'extends'", "'final'", "':'", "'['", "']'", "','", "'isa'", "'if'", "'then'", "'or'", "'conditions'", "'condition'", "'effects'", "'procedure'", "'sub'", "'cost'", "'('", "')'", "'areall'", "'isset'", "'effect'", "'goal'", "'constraint'", "'global'", "'always'", "'sometime'", "'within'", "'after'", "'before'", "'foreach'", "'as'", "'forall'", "'exist'", "'forsome'", "'='", "':different'", "'not'", "'is'", "'in'", "'isnot'", "'isnt'", "'has'", "'total('", "'new'", "'delete'", "'add('", "'remove('", "'any'", "'.'", "'isref'", "'either'", "'!='", "'+='", "'-='", "'*='", "'/='", "'>'", "'>='", "'<'", "'<='" ) end class Parser < ANTLR3::Parser @grammar_home = SfpLang include ANTLR3::ASTBuilder RULE_METHODS = [ :sfp, :constraints, :include, :include_file, :header, :state, :composite, :class_def, :extends_class, :attribute, :attribute_stmt, :object_schema, :object_schemata, :object_def, :object_body, :object_attribute, :state_dependency, :dep_effect, :op_param, :op_conditions, :op_effects, :op_statement, :procedure, :parameters, :parameter, :conditions, :effects, :goal_constraint, :global_constraint, :sometime_constraint, :goal_body, :nested_constraint, :constraint, :constraint_body, :constraint_namespace, :constraint_iterator, :quantification_keyword, :constraint_class_quantification, :constraint_different, :constraint_statement, :total_constraint, :total_statement, :comp_value, :conditional_constraint, :conditional_constraint_if_part, :conditional_constraint_then_part, :effect_body, :mutation_iterator, :mutation, :set_value, :set_item, :value, :primitive_value, :path, :path_with_index, :id_ref, :reference, :reference_type, :set_type, :probability_op, :equals_op, :not_equals_op, :binary_op, :binary_comp ].freeze include TokenData begin generated_using( "SfpLang.g", "3.2.1-SNAPSHOT Jul 31, 2010 19:34:52", "1.8.11" ) rescue NoMethodError => error # ignore end def initialize( input, options = {} ) super( input, options ) end include Sfp::SfpLangHelper # - - - - - - - - - - - - Rules - - - - - - - - - - - - - SfpReturnValue = define_return_scope # # parser rule sfp # # (in SfpLang.g) # 39:1: sfp : ( NL )* ( ( object_def | state | constraints ) ( NL )* | include | class_def | procedure )* ; # def sfp # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 1 ) return_value = SfpReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL1__ = nil __NL5__ = nil object_def2 = nil state3 = nil constraints4 = nil include6 = nil class_def7 = nil procedure8 = nil tree_for_NL1 = nil tree_for_NL5 = nil begin root_0 = @adaptor.create_flat_list # at line 40:4: ( NL )* ( ( object_def | state | constraints ) ( NL )* | include | class_def | procedure )* # --> action self.init # <-- action # at line 41:3: ( NL )* while true # decision 1 alt_1 = 2 look_1_0 = @input.peek( 1 ) if ( look_1_0 == NL ) alt_1 = 1 end case alt_1 when 1 # at line 41:3: NL __NL1__ = match( NL, TOKENS_FOLLOWING_NL_IN_sfp_49 ) tree_for_NL1 = @adaptor.create_with_payload( __NL1__ ) @adaptor.add_child( root_0, tree_for_NL1 ) else break # out of loop for decision 1 end end # loop for decision 1 # at line 43:3: ( ( object_def | state | constraints ) ( NL )* | include | class_def | procedure )* while true # decision 4 alt_4 = 5 case look_4 = @input.peek( 1 ) when ID, T__46, T__48, T__49, T__50 then alt_4 = 1 when T__18 then alt_4 = 2 when T__23, T__24 then alt_4 = 3 when T__38, T__39 then alt_4 = 4 end case alt_4 when 1 # at line 43:5: ( object_def | state | constraints ) ( NL )* # at line 43:5: ( object_def | state | constraints ) alt_2 = 3 look_2_0 = @input.peek( 1 ) if ( look_2_0 == ID ) look_2_1 = @input.peek( 2 ) if ( look_2_1 == T__19 ) alt_2 = 2 elsif ( look_2_1 == EOF || look_2_1 == NL || look_2_1 == ID || look_2_1 == T__18 || look_2_1 == T__20 || look_2_1.between?( T__23, T__25 ) || look_2_1 == T__31 || look_2_1.between?( T__38, T__39 ) || look_2_1 == T__46 || look_2_1.between?( T__48, T__50 ) ) alt_2 = 1 else raise NoViableAlternative( "", 2, 1 ) end elsif ( look_2_0 == T__46 || look_2_0.between?( T__48, T__50 ) ) alt_2 = 3 else raise NoViableAlternative( "", 2, 0 ) end case alt_2 when 1 # at line 43:6: object_def @state.following.push( TOKENS_FOLLOWING_object_def_IN_sfp_60 ) object_def2 = object_def @state.following.pop @adaptor.add_child( root_0, object_def2.tree ) when 2 # at line 43:19: state @state.following.push( TOKENS_FOLLOWING_state_IN_sfp_64 ) state3 = state @state.following.pop @adaptor.add_child( root_0, state3.tree ) when 3 # at line 43:27: constraints @state.following.push( TOKENS_FOLLOWING_constraints_IN_sfp_68 ) constraints4 = constraints @state.following.pop @adaptor.add_child( root_0, constraints4.tree ) end # at line 43:40: ( NL )* while true # decision 3 alt_3 = 2 look_3_0 = @input.peek( 1 ) if ( look_3_0 == NL ) alt_3 = 1 end case alt_3 when 1 # at line 43:40: NL __NL5__ = match( NL, TOKENS_FOLLOWING_NL_IN_sfp_71 ) tree_for_NL5 = @adaptor.create_with_payload( __NL5__ ) @adaptor.add_child( root_0, tree_for_NL5 ) else break # out of loop for decision 3 end end # loop for decision 3 when 2 # at line 43:46: include @state.following.push( TOKENS_FOLLOWING_include_IN_sfp_76 ) include6 = include @state.following.pop @adaptor.add_child( root_0, include6.tree ) when 3 # at line 43:56: class_def @state.following.push( TOKENS_FOLLOWING_class_def_IN_sfp_80 ) class_def7 = class_def @state.following.pop @adaptor.add_child( root_0, class_def7.tree ) when 4 # at line 43:68: procedure @state.following.push( TOKENS_FOLLOWING_procedure_IN_sfp_84 ) procedure8 = procedure @state.following.pop @adaptor.add_child( root_0, procedure8.tree ) else break # out of loop for decision 4 end end # loop for decision 4 # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 1 ) end return return_value end ConstraintsReturnValue = define_return_scope # # parser rule constraints # # (in SfpLang.g) # 47:1: constraints : ( goal_constraint | global_constraint | sometime_constraint ); # def constraints # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 2 ) return_value = ConstraintsReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil goal_constraint9 = nil global_constraint10 = nil sometime_constraint11 = nil begin # at line 48:2: ( goal_constraint | global_constraint | sometime_constraint ) alt_5 = 3 case look_5 = @input.peek( 1 ) when T__46 then alt_5 = 1 when T__48, T__49 then alt_5 = 2 when T__50 then alt_5 = 3 else raise NoViableAlternative( "", 5, 0 ) end case alt_5 when 1 root_0 = @adaptor.create_flat_list # at line 48:4: goal_constraint @state.following.push( TOKENS_FOLLOWING_goal_constraint_IN_constraints_101 ) goal_constraint9 = goal_constraint @state.following.pop @adaptor.add_child( root_0, goal_constraint9.tree ) when 2 root_0 = @adaptor.create_flat_list # at line 49:4: global_constraint @state.following.push( TOKENS_FOLLOWING_global_constraint_IN_constraints_106 ) global_constraint10 = global_constraint @state.following.pop @adaptor.add_child( root_0, global_constraint10.tree ) when 3 root_0 = @adaptor.create_flat_list # at line 50:4: sometime_constraint @state.following.push( TOKENS_FOLLOWING_sometime_constraint_IN_constraints_111 ) sometime_constraint11 = sometime_constraint @state.following.pop @adaptor.add_child( root_0, sometime_constraint11.tree ) end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 2 ) end return return_value end IncludeReturnValue = define_return_scope # # parser rule include # # (in SfpLang.g) # 71:1: include : 'include' include_file ( NL )+ ; # def include # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 3 ) return_value = IncludeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal12 = nil __NL14__ = nil include_file13 = nil tree_for_string_literal12 = nil tree_for_NL14 = nil begin root_0 = @adaptor.create_flat_list # at line 72:4: 'include' include_file ( NL )+ string_literal12 = match( T__18, TOKENS_FOLLOWING_T__18_IN_include_125 ) tree_for_string_literal12 = @adaptor.create_with_payload( string_literal12 ) @adaptor.add_child( root_0, tree_for_string_literal12 ) @state.following.push( TOKENS_FOLLOWING_include_file_IN_include_127 ) include_file13 = include_file @state.following.pop @adaptor.add_child( root_0, include_file13.tree ) # at file 72:27: ( NL )+ match_count_6 = 0 while true alt_6 = 2 look_6_0 = @input.peek( 1 ) if ( look_6_0 == NL ) alt_6 = 1 end case alt_6 when 1 # at line 72:27: NL __NL14__ = match( NL, TOKENS_FOLLOWING_NL_IN_include_129 ) tree_for_NL14 = @adaptor.create_with_payload( __NL14__ ) @adaptor.add_child( root_0, tree_for_NL14 ) else match_count_6 > 0 and break eee = EarlyExit(6) raise eee end match_count_6 += 1 end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 3 ) end return return_value end IncludeFileReturnValue = define_return_scope # # parser rule include_file # # (in SfpLang.g) # 75:1: include_file : STRING ; # def include_file # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 4 ) return_value = IncludeFileReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __STRING15__ = nil tree_for_STRING15 = nil begin root_0 = @adaptor.create_flat_list # at line 76:4: STRING __STRING15__ = match( STRING, TOKENS_FOLLOWING_STRING_IN_include_file_141 ) tree_for_STRING15 = @adaptor.create_with_payload( __STRING15__ ) @adaptor.add_child( root_0, tree_for_STRING15 ) # --> action self.process_file(__STRING15__.text[1,__STRING15__.text.length-2]) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 4 ) end return return_value end HeaderReturnValue = define_return_scope # # parser rule header # # (in SfpLang.g) # 80:1: header : ( class_def | procedure ); # def header # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 5 ) return_value = HeaderReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil class_def16 = nil procedure17 = nil begin # at line 81:2: ( class_def | procedure ) alt_7 = 2 look_7_0 = @input.peek( 1 ) if ( look_7_0.between?( T__23, T__24 ) ) alt_7 = 1 elsif ( look_7_0.between?( T__38, T__39 ) ) alt_7 = 2 else raise NoViableAlternative( "", 7, 0 ) end case alt_7 when 1 root_0 = @adaptor.create_flat_list # at line 81:4: class_def @state.following.push( TOKENS_FOLLOWING_class_def_IN_header_157 ) class_def16 = class_def @state.following.pop @adaptor.add_child( root_0, class_def16.tree ) when 2 root_0 = @adaptor.create_flat_list # at line 82:4: procedure @state.following.push( TOKENS_FOLLOWING_procedure_IN_header_162 ) procedure17 = procedure @state.following.pop @adaptor.add_child( root_0, procedure17.tree ) end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 5 ) end return return_value end StateReturnValue = define_return_scope # # parser rule state # # (in SfpLang.g) # 85:1: state : ID 'state' ( NL )* '{' ( NL )* ( attribute )* '}' ; # def state # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 6 ) return_value = StateReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID18__ = nil string_literal19 = nil __NL20__ = nil char_literal21 = nil __NL22__ = nil char_literal24 = nil attribute23 = nil tree_for_ID18 = nil tree_for_string_literal19 = nil tree_for_NL20 = nil tree_for_char_literal21 = nil tree_for_NL22 = nil tree_for_char_literal24 = nil begin root_0 = @adaptor.create_flat_list # at line 86:4: ID 'state' ( NL )* '{' ( NL )* ( attribute )* '}' __ID18__ = match( ID, TOKENS_FOLLOWING_ID_IN_state_173 ) tree_for_ID18 = @adaptor.create_with_payload( __ID18__ ) @adaptor.add_child( root_0, tree_for_ID18 ) string_literal19 = match( T__19, TOKENS_FOLLOWING_T__19_IN_state_175 ) tree_for_string_literal19 = @adaptor.create_with_payload( string_literal19 ) @adaptor.add_child( root_0, tree_for_string_literal19 ) # at line 86:15: ( NL )* while true # decision 8 alt_8 = 2 look_8_0 = @input.peek( 1 ) if ( look_8_0 == NL ) alt_8 = 1 end case alt_8 when 1 # at line 86:15: NL __NL20__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_177 ) tree_for_NL20 = @adaptor.create_with_payload( __NL20__ ) @adaptor.add_child( root_0, tree_for_NL20 ) else break # out of loop for decision 8 end end # loop for decision 8 # --> action @now[__ID18__.text] = { '_self' => __ID18__.text, '_context' => 'state', '_parent' => @now } @now = @now[__ID18__.text] # <-- action char_literal21 = match( T__20, TOKENS_FOLLOWING_T__20_IN_state_186 ) tree_for_char_literal21 = @adaptor.create_with_payload( char_literal21 ) @adaptor.add_child( root_0, tree_for_char_literal21 ) # at line 94:7: ( NL )* while true # decision 9 alt_9 = 2 look_9_0 = @input.peek( 1 ) if ( look_9_0 == NL ) alt_9 = 1 end case alt_9 when 1 # at line 94:7: NL __NL22__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_188 ) tree_for_NL22 = @adaptor.create_with_payload( __NL22__ ) @adaptor.add_child( root_0, tree_for_NL22 ) else break # out of loop for decision 9 end end # loop for decision 9 # at line 95:3: ( attribute )* while true # decision 10 alt_10 = 2 look_10_0 = @input.peek( 1 ) if ( look_10_0 == ID || look_10_0 == T__26 ) alt_10 = 1 end case alt_10 when 1 # at line 95:3: attribute @state.following.push( TOKENS_FOLLOWING_attribute_IN_state_193 ) attribute23 = attribute @state.following.pop @adaptor.add_child( root_0, attribute23.tree ) else break # out of loop for decision 10 end end # loop for decision 10 char_literal24 = match( T__21, TOKENS_FOLLOWING_T__21_IN_state_198 ) tree_for_char_literal24 = @adaptor.create_with_payload( char_literal24 ) @adaptor.add_child( root_0, tree_for_char_literal24 ) # --> action self.goto_parent(true) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 6 ) end return return_value end CompositeReturnValue = define_return_scope # # parser rule composite # # (in SfpLang.g) # 100:1: composite : 'composite' ID '{' ( NL )* ( attribute | constraint )* '}' ( NL )* ; # def composite # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 7 ) return_value = CompositeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal25 = nil __ID26__ = nil char_literal27 = nil __NL28__ = nil char_literal31 = nil __NL32__ = nil attribute29 = nil constraint30 = nil tree_for_string_literal25 = nil tree_for_ID26 = nil tree_for_char_literal27 = nil tree_for_NL28 = nil tree_for_char_literal31 = nil tree_for_NL32 = nil begin root_0 = @adaptor.create_flat_list # at line 101:4: 'composite' ID '{' ( NL )* ( attribute | constraint )* '}' ( NL )* string_literal25 = match( T__22, TOKENS_FOLLOWING_T__22_IN_composite_213 ) tree_for_string_literal25 = @adaptor.create_with_payload( string_literal25 ) @adaptor.add_child( root_0, tree_for_string_literal25 ) __ID26__ = match( ID, TOKENS_FOLLOWING_ID_IN_composite_215 ) tree_for_ID26 = @adaptor.create_with_payload( __ID26__ ) @adaptor.add_child( root_0, tree_for_ID26 ) # --> action @now[__ID26__.text] = { '_self' => __ID26__.text, '_context' => 'composite', '_parent' => @now } @now = @now[__ID26__.text] # <-- action char_literal27 = match( T__20, TOKENS_FOLLOWING_T__20_IN_composite_223 ) tree_for_char_literal27 = @adaptor.create_with_payload( char_literal27 ) @adaptor.add_child( root_0, tree_for_char_literal27 ) # at line 109:7: ( NL )* while true # decision 11 alt_11 = 2 look_11_0 = @input.peek( 1 ) if ( look_11_0 == NL ) alt_11 = 1 end case alt_11 when 1 # at line 109:7: NL __NL28__ = match( NL, TOKENS_FOLLOWING_NL_IN_composite_225 ) tree_for_NL28 = @adaptor.create_with_payload( __NL28__ ) @adaptor.add_child( root_0, tree_for_NL28 ) else break # out of loop for decision 11 end end # loop for decision 11 # at line 109:11: ( attribute | constraint )* while true # decision 12 alt_12 = 3 look_12_0 = @input.peek( 1 ) if ( look_12_0 == ID || look_12_0 == T__26 ) alt_12 = 1 elsif ( look_12_0 == T__47 ) alt_12 = 2 end case alt_12 when 1 # at line 109:13: attribute @state.following.push( TOKENS_FOLLOWING_attribute_IN_composite_230 ) attribute29 = attribute @state.following.pop @adaptor.add_child( root_0, attribute29.tree ) when 2 # at line 109:25: constraint @state.following.push( TOKENS_FOLLOWING_constraint_IN_composite_234 ) constraint30 = constraint @state.following.pop @adaptor.add_child( root_0, constraint30.tree ) else break # out of loop for decision 12 end end # loop for decision 12 char_literal31 = match( T__21, TOKENS_FOLLOWING_T__21_IN_composite_239 ) tree_for_char_literal31 = @adaptor.create_with_payload( char_literal31 ) @adaptor.add_child( root_0, tree_for_char_literal31 ) # at line 109:43: ( NL )* while true # decision 13 alt_13 = 2 look_13_0 = @input.peek( 1 ) if ( look_13_0 == NL ) alt_13 = 1 end case alt_13 when 1 # at line 109:43: NL __NL32__ = match( NL, TOKENS_FOLLOWING_NL_IN_composite_241 ) tree_for_NL32 = @adaptor.create_with_payload( __NL32__ ) @adaptor.add_child( root_0, tree_for_NL32 ) else break # out of loop for decision 13 end end # loop for decision 13 # --> action self.goto_parent(true) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 7 ) end return return_value end ClassDefReturnValue = define_return_scope # # parser rule class_def # # (in SfpLang.g) # 113:1: class_def : ( 'class' | 'schema' ) ID ( extends_class )? ( '{' ( NL )* ( attribute | procedure )* '}' )? ( NL )* ; # def class_def # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 8 ) return_value = ClassDefReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set33 = nil __ID34__ = nil char_literal36 = nil __NL37__ = nil char_literal40 = nil __NL41__ = nil extends_class35 = nil attribute38 = nil procedure39 = nil tree_for_set33 = nil tree_for_ID34 = nil tree_for_char_literal36 = nil tree_for_NL37 = nil tree_for_char_literal40 = nil tree_for_NL41 = nil begin root_0 = @adaptor.create_flat_list # at line 114:4: ( 'class' | 'schema' ) ID ( extends_class )? ( '{' ( NL )* ( attribute | procedure )* '}' )? ( NL )* set33 = @input.look if @input.peek( 1 ).between?( T__23, T__24 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set33 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end __ID34__ = match( ID, TOKENS_FOLLOWING_ID_IN_class_def_263 ) tree_for_ID34 = @adaptor.create_with_payload( __ID34__ ) @adaptor.add_child( root_0, tree_for_ID34 ) # --> action @now[__ID34__.text] = { '_self' => __ID34__.text, '_context' => 'class', '_parent' => @now, } @now = @now[__ID34__.text] # <-- action # at line 122:3: ( extends_class )? alt_14 = 2 look_14_0 = @input.peek( 1 ) if ( look_14_0 == T__25 ) alt_14 = 1 end case alt_14 when 1 # at line 122:4: extends_class @state.following.push( TOKENS_FOLLOWING_extends_class_IN_class_def_272 ) extends_class35 = extends_class @state.following.pop @adaptor.add_child( root_0, extends_class35.tree ) # --> action @now['_extends'] = ( extends_class35.nil? ? nil : extends_class35.val ) # <-- action end # at line 127:3: ( '{' ( NL )* ( attribute | procedure )* '}' )? alt_17 = 2 look_17_0 = @input.peek( 1 ) if ( look_17_0 == T__20 ) alt_17 = 1 end case alt_17 when 1 # at line 127:4: '{' ( NL )* ( attribute | procedure )* '}' char_literal36 = match( T__20, TOKENS_FOLLOWING_T__20_IN_class_def_286 ) tree_for_char_literal36 = @adaptor.create_with_payload( char_literal36 ) @adaptor.add_child( root_0, tree_for_char_literal36 ) # at line 127:8: ( NL )* while true # decision 15 alt_15 = 2 look_15_0 = @input.peek( 1 ) if ( look_15_0 == NL ) alt_15 = 1 end case alt_15 when 1 # at line 127:8: NL __NL37__ = match( NL, TOKENS_FOLLOWING_NL_IN_class_def_288 ) tree_for_NL37 = @adaptor.create_with_payload( __NL37__ ) @adaptor.add_child( root_0, tree_for_NL37 ) else break # out of loop for decision 15 end end # loop for decision 15 # at line 127:12: ( attribute | procedure )* while true # decision 16 alt_16 = 3 look_16_0 = @input.peek( 1 ) if ( look_16_0 == ID || look_16_0 == T__26 ) alt_16 = 1 elsif ( look_16_0.between?( T__38, T__39 ) ) alt_16 = 2 end case alt_16 when 1 # at line 127:14: attribute @state.following.push( TOKENS_FOLLOWING_attribute_IN_class_def_293 ) attribute38 = attribute @state.following.pop @adaptor.add_child( root_0, attribute38.tree ) when 2 # at line 127:26: procedure @state.following.push( TOKENS_FOLLOWING_procedure_IN_class_def_297 ) procedure39 = procedure @state.following.pop @adaptor.add_child( root_0, procedure39.tree ) else break # out of loop for decision 16 end end # loop for decision 16 char_literal40 = match( T__21, TOKENS_FOLLOWING_T__21_IN_class_def_302 ) tree_for_char_literal40 = @adaptor.create_with_payload( char_literal40 ) @adaptor.add_child( root_0, tree_for_char_literal40 ) end # at line 127:45: ( NL )* while true # decision 18 alt_18 = 2 look_18_0 = @input.peek( 1 ) if ( look_18_0 == NL ) alt_18 = 1 end case alt_18 when 1 # at line 127:45: NL __NL41__ = match( NL, TOKENS_FOLLOWING_NL_IN_class_def_306 ) tree_for_NL41 = @adaptor.create_with_payload( __NL41__ ) @adaptor.add_child( root_0, tree_for_NL41 ) else break # out of loop for decision 18 end end # loop for decision 18 # --> action if not @now.has_key?('_extends') @now['_extends'] = '$.Object' @now['_super'] = ['$.Object'] end expand_class(@now) self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 8 ) end return return_value end ExtendsClassReturnValue = define_return_scope :val # # parser rule extends_class # # (in SfpLang.g) # 138:1: extends_class returns [val] : 'extends' path ; # def extends_class # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 9 ) return_value = ExtendsClassReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal42 = nil path43 = nil tree_for_string_literal42 = nil begin root_0 = @adaptor.create_flat_list # at line 139:4: 'extends' path string_literal42 = match( T__25, TOKENS_FOLLOWING_T__25_IN_extends_class_327 ) tree_for_string_literal42 = @adaptor.create_with_payload( string_literal42 ) @adaptor.add_child( root_0, tree_for_string_literal42 ) @state.following.push( TOKENS_FOLLOWING_path_IN_extends_class_329 ) path43 = path @state.following.pop @adaptor.add_child( root_0, path43.tree ) # --> action return_value.val = self.to_ref(( path43 && @input.to_s( path43.start, path43.stop ) )) @unexpanded_classes.push(@now) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 9 ) end return return_value end AttributeReturnValue = define_return_scope # # parser rule attribute # # (in SfpLang.g) # 146:1: attribute : ( 'final' )? attribute_stmt ; # def attribute # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 10 ) return_value = AttributeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal44 = nil attribute_stmt45 = nil tree_for_string_literal44 = nil begin root_0 = @adaptor.create_flat_list # at line 147:4: ( 'final' )? attribute_stmt # --> action @is_final = false @now['_finals'] = [] if !@now.has_key? '_finals' # <-- action # at line 151:3: ( 'final' )? alt_19 = 2 look_19_0 = @input.peek( 1 ) if ( look_19_0 == T__26 ) alt_19 = 1 end case alt_19 when 1 # at line 151:4: 'final' string_literal44 = match( T__26, TOKENS_FOLLOWING_T__26_IN_attribute_349 ) tree_for_string_literal44 = @adaptor.create_with_payload( string_literal44 ) @adaptor.add_child( root_0, tree_for_string_literal44 ) # --> action @is_final = true # <-- action end @state.following.push( TOKENS_FOLLOWING_attribute_stmt_IN_attribute_355 ) attribute_stmt45 = attribute_stmt @state.following.pop @adaptor.add_child( root_0, attribute_stmt45.tree ) # --> action @now['_finals'] << ( attribute_stmt45.nil? ? nil : attribute_stmt45.id ) if @is_final and !( attribute_stmt45.nil? ? nil : attribute_stmt45.id ).nil? # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 10 ) end return return_value end AttributeStmtReturnValue = define_return_scope :id # # parser rule attribute_stmt # # (in SfpLang.g) # 157:1: attribute_stmt returns [id] : ( ID equals_op value ( NL )+ | ID reference_type ( NL )+ | ID set_type ( NL )+ | ID probability_op set_value ( NL )+ | ID ':' path ( NL )+ | object_def ( NL )+ ); # def attribute_stmt # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 11 ) return_value = AttributeStmtReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID46__ = nil __NL49__ = nil __ID50__ = nil __NL52__ = nil __ID53__ = nil __NL55__ = nil __ID56__ = nil __NL59__ = nil __ID60__ = nil char_literal61 = nil __NL63__ = nil __NL65__ = nil equals_op47 = nil value48 = nil reference_type51 = nil set_type54 = nil probability_op57 = nil set_value58 = nil path62 = nil object_def64 = nil tree_for_ID46 = nil tree_for_NL49 = nil tree_for_ID50 = nil tree_for_NL52 = nil tree_for_ID53 = nil tree_for_NL55 = nil tree_for_ID56 = nil tree_for_NL59 = nil tree_for_ID60 = nil tree_for_char_literal61 = nil tree_for_NL63 = nil tree_for_NL65 = nil begin # at line 158:2: ( ID equals_op value ( NL )+ | ID reference_type ( NL )+ | ID set_type ( NL )+ | ID probability_op set_value ( NL )+ | ID ':' path ( NL )+ | object_def ( NL )+ ) alt_26 = 6 look_26_0 = @input.peek( 1 ) if ( look_26_0 == ID ) case look_26 = @input.peek( 2 ) when T__27 then alt_26 = 5 when T__59, T__62 then alt_26 = 1 when T__74 then alt_26 = 2 when T__44 then alt_26 = 3 when T__75 then alt_26 = 4 when NL, T__20, T__25, T__31 then alt_26 = 6 else raise NoViableAlternative( "", 26, 1 ) end else raise NoViableAlternative( "", 26, 0 ) end case alt_26 when 1 root_0 = @adaptor.create_flat_list # at line 158:4: ID equals_op value ( NL )+ __ID46__ = match( ID, TOKENS_FOLLOWING_ID_IN_attribute_stmt_374 ) tree_for_ID46 = @adaptor.create_with_payload( __ID46__ ) @adaptor.add_child( root_0, tree_for_ID46 ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_attribute_stmt_376 ) equals_op47 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op47.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_attribute_stmt_378 ) value48 = value @state.following.pop @adaptor.add_child( root_0, value48.tree ) # at file 158:23: ( NL )+ match_count_20 = 0 while true alt_20 = 2 look_20_0 = @input.peek( 1 ) if ( look_20_0 == NL ) alt_20 = 1 end case alt_20 when 1 # at line 158:23: NL __NL49__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_380 ) tree_for_NL49 = @adaptor.create_with_payload( __NL49__ ) @adaptor.add_child( root_0, tree_for_NL49 ) else match_count_20 > 0 and break eee = EarlyExit(20) raise eee end match_count_20 += 1 end # --> action if @now.has_key?(__ID46__.text) and @now[__ID46__.text].is_a?(Hash) and @now[__ID46__.text].isset and ( value48.nil? ? nil : value48.type ) == 'Set' ( value48.nil? ? nil : value48.val ).each { |v| @now[__ID46__.text]['_values'].push(v) } else @now[__ID46__.text] = ( value48.nil? ? nil : value48.val ) end return_value.id = __ID46__.text # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 168:4: ID reference_type ( NL )+ __ID50__ = match( ID, TOKENS_FOLLOWING_ID_IN_attribute_stmt_390 ) tree_for_ID50 = @adaptor.create_with_payload( __ID50__ ) @adaptor.add_child( root_0, tree_for_ID50 ) @state.following.push( TOKENS_FOLLOWING_reference_type_IN_attribute_stmt_392 ) reference_type51 = reference_type @state.following.pop @adaptor.add_child( root_0, reference_type51.tree ) # at file 168:22: ( NL )+ match_count_21 = 0 while true alt_21 = 2 look_21_0 = @input.peek( 1 ) if ( look_21_0 == NL ) alt_21 = 1 end case alt_21 when 1 # at line 168:22: NL __NL52__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_394 ) tree_for_NL52 = @adaptor.create_with_payload( __NL52__ ) @adaptor.add_child( root_0, tree_for_NL52 ) else match_count_21 > 0 and break eee = EarlyExit(21) raise eee end match_count_21 += 1 end # --> action @now[__ID50__.text] = ( reference_type51.nil? ? nil : reference_type51.val ) return_value.id = __ID50__.text # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 173:4: ID set_type ( NL )+ __ID53__ = match( ID, TOKENS_FOLLOWING_ID_IN_attribute_stmt_404 ) tree_for_ID53 = @adaptor.create_with_payload( __ID53__ ) @adaptor.add_child( root_0, tree_for_ID53 ) @state.following.push( TOKENS_FOLLOWING_set_type_IN_attribute_stmt_406 ) set_type54 = set_type @state.following.pop @adaptor.add_child( root_0, set_type54.tree ) # at file 173:16: ( NL )+ match_count_22 = 0 while true alt_22 = 2 look_22_0 = @input.peek( 1 ) if ( look_22_0 == NL ) alt_22 = 1 end case alt_22 when 1 # at line 173:16: NL __NL55__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_408 ) tree_for_NL55 = @adaptor.create_with_payload( __NL55__ ) @adaptor.add_child( root_0, tree_for_NL55 ) else match_count_22 > 0 and break eee = EarlyExit(22) raise eee end match_count_22 += 1 end # --> action @now[__ID53__.text] = ( set_type54.nil? ? nil : set_type54.val ) return_value.id = __ID53__.text # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 178:4: ID probability_op set_value ( NL )+ __ID56__ = match( ID, TOKENS_FOLLOWING_ID_IN_attribute_stmt_418 ) tree_for_ID56 = @adaptor.create_with_payload( __ID56__ ) @adaptor.add_child( root_0, tree_for_ID56 ) @state.following.push( TOKENS_FOLLOWING_probability_op_IN_attribute_stmt_420 ) probability_op57 = probability_op @state.following.pop @adaptor.add_child( root_0, probability_op57.tree ) @state.following.push( TOKENS_FOLLOWING_set_value_IN_attribute_stmt_422 ) set_value58 = set_value @state.following.pop @adaptor.add_child( root_0, set_value58.tree ) # at file 178:32: ( NL )+ match_count_23 = 0 while true alt_23 = 2 look_23_0 = @input.peek( 1 ) if ( look_23_0 == NL ) alt_23 = 1 end case alt_23 when 1 # at line 178:32: NL __NL59__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_424 ) tree_for_NL59 = @adaptor.create_with_payload( __NL59__ ) @adaptor.add_child( root_0, tree_for_NL59 ) else match_count_23 > 0 and break eee = EarlyExit(23) raise eee end match_count_23 += 1 end # --> action @conformant = true @now[__ID56__.text] = { '_self' => __ID56__.text, '_context' => 'either', '_parent' => @now, '_values' => ( set_value58.nil? ? nil : set_value58.val ) } return_value.id = __ID56__.text # <-- action when 5 root_0 = @adaptor.create_flat_list # at line 188:4: ID ':' path ( NL )+ __ID60__ = match( ID, TOKENS_FOLLOWING_ID_IN_attribute_stmt_434 ) tree_for_ID60 = @adaptor.create_with_payload( __ID60__ ) @adaptor.add_child( root_0, tree_for_ID60 ) char_literal61 = match( T__27, TOKENS_FOLLOWING_T__27_IN_attribute_stmt_436 ) tree_for_char_literal61 = @adaptor.create_with_payload( char_literal61 ) @adaptor.add_child( root_0, tree_for_char_literal61 ) @state.following.push( TOKENS_FOLLOWING_path_IN_attribute_stmt_438 ) path62 = path @state.following.pop @adaptor.add_child( root_0, path62.tree ) # at file 188:16: ( NL )+ match_count_24 = 0 while true alt_24 = 2 look_24_0 = @input.peek( 1 ) if ( look_24_0 == NL ) alt_24 = 1 end case alt_24 when 1 # at line 188:16: NL __NL63__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_440 ) tree_for_NL63 = @adaptor.create_with_payload( __NL63__ ) @adaptor.add_child( root_0, tree_for_NL63 ) else match_count_24 > 0 and break eee = EarlyExit(24) raise eee end match_count_24 += 1 end # --> action case ( path62 && @input.to_s( path62.start, path62.stop ) ) when 'String' @now[__ID60__.text] = { '_context' => 'any_value', '_isa' => '$.String' } when 'Bool' @now[__ID60__.text] = { '_context' => 'any_value', '_isa' => '$.Boolean' } when 'Int' @now[__ID60__.text] = { '_context' => 'any_value', '_isa' => '$.Number' } else raise Exception, "Use isa/isref for any non-primitive type (#{( path62 && @input.to_s( path62.start, path62.stop ) )})." end return_value.id = __ID60__.text # <-- action when 6 root_0 = @adaptor.create_flat_list # at line 208:4: object_def ( NL )+ @state.following.push( TOKENS_FOLLOWING_object_def_IN_attribute_stmt_450 ) object_def64 = object_def @state.following.pop @adaptor.add_child( root_0, object_def64.tree ) # at file 208:15: ( NL )+ match_count_25 = 0 while true alt_25 = 2 look_25_0 = @input.peek( 1 ) if ( look_25_0 == NL ) alt_25 = 1 end case alt_25 when 1 # at line 208:15: NL __NL65__ = match( NL, TOKENS_FOLLOWING_NL_IN_attribute_stmt_452 ) tree_for_NL65 = @adaptor.create_with_payload( __NL65__ ) @adaptor.add_child( root_0, tree_for_NL65 ) else match_count_25 > 0 and break eee = EarlyExit(25) raise eee end match_count_25 += 1 end # --> action return_value.id = nil # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 11 ) end return return_value end ObjectSchemaReturnValue = define_return_scope # # parser rule object_schema # # (in SfpLang.g) # 212:1: object_schema : path ( '[' NUMBER ']' )? ; # def object_schema # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 12 ) return_value = ObjectSchemaReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal67 = nil __NUMBER68__ = nil char_literal69 = nil path66 = nil tree_for_char_literal67 = nil tree_for_NUMBER68 = nil tree_for_char_literal69 = nil begin root_0 = @adaptor.create_flat_list # at line 213:4: path ( '[' NUMBER ']' )? @state.following.push( TOKENS_FOLLOWING_path_IN_object_schema_468 ) path66 = path @state.following.pop @adaptor.add_child( root_0, path66.tree ) # at line 213:8: ( '[' NUMBER ']' )? alt_27 = 2 look_27_0 = @input.peek( 1 ) if ( look_27_0 == T__28 ) alt_27 = 1 end case alt_27 when 1 # at line 213:9: '[' NUMBER ']' char_literal67 = match( T__28, TOKENS_FOLLOWING_T__28_IN_object_schema_470 ) tree_for_char_literal67 = @adaptor.create_with_payload( char_literal67 ) @adaptor.add_child( root_0, tree_for_char_literal67 ) __NUMBER68__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_object_schema_472 ) tree_for_NUMBER68 = @adaptor.create_with_payload( __NUMBER68__ ) @adaptor.add_child( root_0, tree_for_NUMBER68 ) # --> action @now['_is_array'] = true # <-- action char_literal69 = match( T__29, TOKENS_FOLLOWING_T__29_IN_object_schema_476 ) tree_for_char_literal69 = @adaptor.create_with_payload( char_literal69 ) @adaptor.add_child( root_0, tree_for_char_literal69 ) end # --> action @now['_isa'] = self.to_ref(( path66 && @input.to_s( path66.start, path66.stop ) )) self.expand_object(@now) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 12 ) end return return_value end ObjectSchemataReturnValue = define_return_scope # # parser rule object_schemata # # (in SfpLang.g) # 220:1: object_schemata : ',' object_schema ; # def object_schemata # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 13 ) return_value = ObjectSchemataReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal70 = nil object_schema71 = nil tree_for_char_literal70 = nil begin root_0 = @adaptor.create_flat_list # at line 221:4: ',' object_schema char_literal70 = match( T__30, TOKENS_FOLLOWING_T__30_IN_object_schemata_493 ) tree_for_char_literal70 = @adaptor.create_with_payload( char_literal70 ) @adaptor.add_child( root_0, tree_for_char_literal70 ) @state.following.push( TOKENS_FOLLOWING_object_schema_IN_object_schemata_495 ) object_schema71 = object_schema @state.following.pop @adaptor.add_child( root_0, object_schema71.tree ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 13 ) end return return_value end ObjectDefReturnValue = define_return_scope # # parser rule object_def # # (in SfpLang.g) # 224:1: object_def : ID ( 'extends' path )? ( 'isa' object_schema ( object_schemata )* )? ( object_body )? ; # def object_def # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 14 ) return_value = ObjectDefReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID72__ = nil string_literal73 = nil string_literal75 = nil path74 = nil object_schema76 = nil object_schemata77 = nil object_body78 = nil tree_for_ID72 = nil tree_for_string_literal73 = nil tree_for_string_literal75 = nil begin root_0 = @adaptor.create_flat_list # at line 225:4: ID ( 'extends' path )? ( 'isa' object_schema ( object_schemata )* )? ( object_body )? # --> action @use_template = false # <-- action __ID72__ = match( ID, TOKENS_FOLLOWING_ID_IN_object_def_510 ) tree_for_ID72 = @adaptor.create_with_payload( __ID72__ ) @adaptor.add_child( root_0, tree_for_ID72 ) # at line 227:3: ( 'extends' path )? alt_28 = 2 look_28_0 = @input.peek( 1 ) if ( look_28_0 == T__25 ) alt_28 = 1 end case alt_28 when 1 # at line 227:4: 'extends' path string_literal73 = match( T__25, TOKENS_FOLLOWING_T__25_IN_object_def_515 ) tree_for_string_literal73 = @adaptor.create_with_payload( string_literal73 ) @adaptor.add_child( root_0, tree_for_string_literal73 ) @state.following.push( TOKENS_FOLLOWING_path_IN_object_def_517 ) path74 = path @state.following.pop @adaptor.add_child( root_0, path74.tree ) # --> action template = @root.at?(( path74 && @input.to_s( path74.start, path74.stop ) )) raise Exception, "Object template #{( path74 && @input.to_s( path74.start, path74.stop ) )} is not found!" if template.is_a?(Sfp::Unknown) or template.is_a?(Sfp::Undefined) raise Exception, "#{( path74 && @input.to_s( path74.start, path74.stop ) )} is not an object!" if !template.is_a?(Hash) or template['_context'] != 'object' @now[__ID72__.text] = Sfp::Helper.deep_clone(template) @now[__ID72__.text].accept(Sfp::Visitor::ParentEliminator.new) @now[__ID72__.text]['_parent'] = @now @now[__ID72__.text]['_self'] = __ID72__.text @now[__ID72__.text].accept(Sfp::Visitor::SfpGenerator.new(@root)) @use_template = true # <-- action end # --> action @now[__ID72__.text] = { '_self' => __ID72__.text, '_context' => 'object', '_parent' => @now, '_isa' => '$.Object' } if not @use_template @now = @now[__ID72__.text] @now['_is_array'] = false # <-- action # at line 251:3: ( 'isa' object_schema ( object_schemata )* )? alt_30 = 2 look_30_0 = @input.peek( 1 ) if ( look_30_0 == T__31 ) alt_30 = 1 end case alt_30 when 1 # at line 251:4: 'isa' object_schema ( object_schemata )* string_literal75 = match( T__31, TOKENS_FOLLOWING_T__31_IN_object_def_535 ) tree_for_string_literal75 = @adaptor.create_with_payload( string_literal75 ) @adaptor.add_child( root_0, tree_for_string_literal75 ) @state.following.push( TOKENS_FOLLOWING_object_schema_IN_object_def_537 ) object_schema76 = object_schema @state.following.pop @adaptor.add_child( root_0, object_schema76.tree ) # at line 251:24: ( object_schemata )* while true # decision 29 alt_29 = 2 look_29_0 = @input.peek( 1 ) if ( look_29_0 == T__30 ) alt_29 = 1 end case alt_29 when 1 # at line 251:25: object_schemata @state.following.push( TOKENS_FOLLOWING_object_schemata_IN_object_def_540 ) object_schemata77 = object_schemata @state.following.pop @adaptor.add_child( root_0, object_schemata77.tree ) else break # out of loop for decision 29 end end # loop for decision 29 end # at line 252:3: ( object_body )? alt_31 = 2 look_31_0 = @input.peek( 1 ) if ( look_31_0 == T__20 ) alt_31 = 1 end case alt_31 when 1 # at line 252:3: object_body @state.following.push( TOKENS_FOLLOWING_object_body_IN_object_def_549 ) object_body78 = object_body @state.following.pop @adaptor.add_child( root_0, object_body78.tree ) end # --> action if @now['_is_array'] @now.delete('_is_array') obj = self.goto_parent() total = $NUMBER.to_s.to_i @arrays[obj.ref] = total for i in 0..(total-1) id = obj['_self'] + '[' + i.to_s + ']' @now[id] = deep_clone(obj) @now[id]['_self'] = id @now[id]['_classes'] = obj['_classes'] end @now.delete(obj['_self']) else self.goto_parent() end # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 14 ) end return return_value end ObjectBodyReturnValue = define_return_scope # # parser rule object_body # # (in SfpLang.g) # 272:1: object_body : '{' ( NL )* ( object_attribute | procedure )* '}' ; # def object_body # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 15 ) return_value = ObjectBodyReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal79 = nil __NL80__ = nil char_literal83 = nil object_attribute81 = nil procedure82 = nil tree_for_char_literal79 = nil tree_for_NL80 = nil tree_for_char_literal83 = nil begin root_0 = @adaptor.create_flat_list # at line 273:4: '{' ( NL )* ( object_attribute | procedure )* '}' char_literal79 = match( T__20, TOKENS_FOLLOWING_T__20_IN_object_body_565 ) tree_for_char_literal79 = @adaptor.create_with_payload( char_literal79 ) @adaptor.add_child( root_0, tree_for_char_literal79 ) # at line 273:8: ( NL )* while true # decision 32 alt_32 = 2 look_32_0 = @input.peek( 1 ) if ( look_32_0 == NL ) alt_32 = 1 end case alt_32 when 1 # at line 273:8: NL __NL80__ = match( NL, TOKENS_FOLLOWING_NL_IN_object_body_567 ) tree_for_NL80 = @adaptor.create_with_payload( __NL80__ ) @adaptor.add_child( root_0, tree_for_NL80 ) else break # out of loop for decision 32 end end # loop for decision 32 # at line 273:12: ( object_attribute | procedure )* while true # decision 33 alt_33 = 3 look_33_0 = @input.peek( 1 ) if ( look_33_0 == ID || look_33_0 == T__26 ) alt_33 = 1 elsif ( look_33_0.between?( T__38, T__39 ) ) alt_33 = 2 end case alt_33 when 1 # at line 273:14: object_attribute @state.following.push( TOKENS_FOLLOWING_object_attribute_IN_object_body_572 ) object_attribute81 = object_attribute @state.following.pop @adaptor.add_child( root_0, object_attribute81.tree ) when 2 # at line 273:33: procedure @state.following.push( TOKENS_FOLLOWING_procedure_IN_object_body_576 ) procedure82 = procedure @state.following.pop @adaptor.add_child( root_0, procedure82.tree ) else break # out of loop for decision 33 end end # loop for decision 33 char_literal83 = match( T__21, TOKENS_FOLLOWING_T__21_IN_object_body_581 ) tree_for_char_literal83 = @adaptor.create_with_payload( char_literal83 ) @adaptor.add_child( root_0, tree_for_char_literal83 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 15 ) end return return_value end ObjectAttributeReturnValue = define_return_scope # # parser rule object_attribute # # (in SfpLang.g) # 276:1: object_attribute : ( attribute | ID equals_op NULL ( NL )+ ); # def object_attribute # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 16 ) return_value = ObjectAttributeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID85__ = nil __NULL87__ = nil __NL88__ = nil attribute84 = nil equals_op86 = nil tree_for_ID85 = nil tree_for_NULL87 = nil tree_for_NL88 = nil begin # at line 277:2: ( attribute | ID equals_op NULL ( NL )+ ) alt_35 = 2 look_35_0 = @input.peek( 1 ) if ( look_35_0 == T__26 ) alt_35 = 1 elsif ( look_35_0 == ID ) look_35_2 = @input.peek( 2 ) if ( look_35_2 == NL || look_35_2 == T__20 || look_35_2 == T__25 || look_35_2 == T__27 || look_35_2 == T__31 || look_35_2 == T__44 || look_35_2.between?( T__74, T__75 ) ) alt_35 = 1 elsif ( look_35_2 == T__59 || look_35_2 == T__62 ) look_35_3 = @input.peek( 3 ) if ( look_35_3.between?( STRING, NUMBER ) || look_35_3.between?( BOOLEAN, MULTILINE_STRING ) || look_35_3 == T__41 || look_35_3 == T__72 ) alt_35 = 1 elsif ( look_35_3 == NULL ) alt_35 = 2 else raise NoViableAlternative( "", 35, 3 ) end else raise NoViableAlternative( "", 35, 2 ) end else raise NoViableAlternative( "", 35, 0 ) end case alt_35 when 1 root_0 = @adaptor.create_flat_list # at line 277:4: attribute @state.following.push( TOKENS_FOLLOWING_attribute_IN_object_attribute_592 ) attribute84 = attribute @state.following.pop @adaptor.add_child( root_0, attribute84.tree ) when 2 root_0 = @adaptor.create_flat_list # at line 278:4: ID equals_op NULL ( NL )+ __ID85__ = match( ID, TOKENS_FOLLOWING_ID_IN_object_attribute_597 ) tree_for_ID85 = @adaptor.create_with_payload( __ID85__ ) @adaptor.add_child( root_0, tree_for_ID85 ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_object_attribute_599 ) equals_op86 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op86.tree ) __NULL87__ = match( NULL, TOKENS_FOLLOWING_NULL_IN_object_attribute_601 ) tree_for_NULL87 = @adaptor.create_with_payload( __NULL87__ ) @adaptor.add_child( root_0, tree_for_NULL87 ) # at file 278:22: ( NL )+ match_count_34 = 0 while true alt_34 = 2 look_34_0 = @input.peek( 1 ) if ( look_34_0 == NL ) alt_34 = 1 end case alt_34 when 1 # at line 278:22: NL __NL88__ = match( NL, TOKENS_FOLLOWING_NL_IN_object_attribute_603 ) tree_for_NL88 = @adaptor.create_with_payload( __NL88__ ) @adaptor.add_child( root_0, tree_for_NL88 ) else match_count_34 > 0 and break eee = EarlyExit(34) raise eee end match_count_34 += 1 end # --> action @now[__ID85__.text] = self.null_value # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 16 ) end return return_value end StateDependencyReturnValue = define_return_scope # # parser rule state_dependency # # (in SfpLang.g) # 282:1: state_dependency : 'if' dep_effect ( NL )* 'then' ( NL )* '{' ( NL )* constraint_body '}' ( ( NL )* 'or' ( NL )* '{' ( NL )* constraint_body '}' )* ( NL )+ ; # def state_dependency # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 17 ) return_value = StateDependencyReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal89 = nil __NL91__ = nil string_literal92 = nil __NL93__ = nil char_literal94 = nil __NL95__ = nil char_literal97 = nil __NL98__ = nil string_literal99 = nil __NL100__ = nil char_literal101 = nil __NL102__ = nil char_literal104 = nil __NL105__ = nil dep_effect90 = nil constraint_body96 = nil constraint_body103 = nil tree_for_string_literal89 = nil tree_for_NL91 = nil tree_for_string_literal92 = nil tree_for_NL93 = nil tree_for_char_literal94 = nil tree_for_NL95 = nil tree_for_char_literal97 = nil tree_for_NL98 = nil tree_for_string_literal99 = nil tree_for_NL100 = nil tree_for_char_literal101 = nil tree_for_NL102 = nil tree_for_char_literal104 = nil tree_for_NL105 = nil begin root_0 = @adaptor.create_flat_list # at line 283:4: 'if' dep_effect ( NL )* 'then' ( NL )* '{' ( NL )* constraint_body '}' ( ( NL )* 'or' ( NL )* '{' ( NL )* constraint_body '}' )* ( NL )+ string_literal89 = match( T__32, TOKENS_FOLLOWING_T__32_IN_state_dependency_619 ) tree_for_string_literal89 = @adaptor.create_with_payload( string_literal89 ) @adaptor.add_child( root_0, tree_for_string_literal89 ) @state.following.push( TOKENS_FOLLOWING_dep_effect_IN_state_dependency_623 ) dep_effect90 = dep_effect @state.following.pop @adaptor.add_child( root_0, dep_effect90.tree ) # at line 284:14: ( NL )* while true # decision 36 alt_36 = 2 look_36_0 = @input.peek( 1 ) if ( look_36_0 == NL ) alt_36 = 1 end case alt_36 when 1 # at line 284:14: NL __NL91__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_625 ) tree_for_NL91 = @adaptor.create_with_payload( __NL91__ ) @adaptor.add_child( root_0, tree_for_NL91 ) else break # out of loop for decision 36 end end # loop for decision 36 string_literal92 = match( T__33, TOKENS_FOLLOWING_T__33_IN_state_dependency_628 ) tree_for_string_literal92 = @adaptor.create_with_payload( string_literal92 ) @adaptor.add_child( root_0, tree_for_string_literal92 ) # at line 284:25: ( NL )* while true # decision 37 alt_37 = 2 look_37_0 = @input.peek( 1 ) if ( look_37_0 == NL ) alt_37 = 1 end case alt_37 when 1 # at line 284:25: NL __NL93__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_630 ) tree_for_NL93 = @adaptor.create_with_payload( __NL93__ ) @adaptor.add_child( root_0, tree_for_NL93 ) else break # out of loop for decision 37 end end # loop for decision 37 char_literal94 = match( T__20, TOKENS_FOLLOWING_T__20_IN_state_dependency_633 ) tree_for_char_literal94 = @adaptor.create_with_payload( char_literal94 ) @adaptor.add_child( root_0, tree_for_char_literal94 ) # at line 285:3: ( NL )* while true # decision 38 alt_38 = 2 look_38_0 = @input.peek( 1 ) if ( look_38_0 == NL ) alt_38 = 1 end case alt_38 when 1 # at line 285:3: NL __NL95__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_637 ) tree_for_NL95 = @adaptor.create_with_payload( __NL95__ ) @adaptor.add_child( root_0, tree_for_NL95 ) else break # out of loop for decision 38 end end # loop for decision 38 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_state_dependency_640 ) constraint_body96 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body96.tree ) char_literal97 = match( T__21, TOKENS_FOLLOWING_T__21_IN_state_dependency_645 ) tree_for_char_literal97 = @adaptor.create_with_payload( char_literal97 ) @adaptor.add_child( root_0, tree_for_char_literal97 ) # at line 287:3: ( ( NL )* 'or' ( NL )* '{' ( NL )* constraint_body '}' )* while true # decision 42 alt_42 = 2 alt_42 = @dfa42.predict( @input ) case alt_42 when 1 # at line 287:5: ( NL )* 'or' ( NL )* '{' ( NL )* constraint_body '}' # at line 287:5: ( NL )* while true # decision 39 alt_39 = 2 look_39_0 = @input.peek( 1 ) if ( look_39_0 == NL ) alt_39 = 1 end case alt_39 when 1 # at line 287:5: NL __NL98__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_651 ) tree_for_NL98 = @adaptor.create_with_payload( __NL98__ ) @adaptor.add_child( root_0, tree_for_NL98 ) else break # out of loop for decision 39 end end # loop for decision 39 string_literal99 = match( T__34, TOKENS_FOLLOWING_T__34_IN_state_dependency_654 ) tree_for_string_literal99 = @adaptor.create_with_payload( string_literal99 ) @adaptor.add_child( root_0, tree_for_string_literal99 ) # at line 287:14: ( NL )* while true # decision 40 alt_40 = 2 look_40_0 = @input.peek( 1 ) if ( look_40_0 == NL ) alt_40 = 1 end case alt_40 when 1 # at line 287:14: NL __NL100__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_656 ) tree_for_NL100 = @adaptor.create_with_payload( __NL100__ ) @adaptor.add_child( root_0, tree_for_NL100 ) else break # out of loop for decision 40 end end # loop for decision 40 char_literal101 = match( T__20, TOKENS_FOLLOWING_T__20_IN_state_dependency_659 ) tree_for_char_literal101 = @adaptor.create_with_payload( char_literal101 ) @adaptor.add_child( root_0, tree_for_char_literal101 ) # at line 288:3: ( NL )* while true # decision 41 alt_41 = 2 look_41_0 = @input.peek( 1 ) if ( look_41_0 == NL ) alt_41 = 1 end case alt_41 when 1 # at line 288:3: NL __NL102__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_663 ) tree_for_NL102 = @adaptor.create_with_payload( __NL102__ ) @adaptor.add_child( root_0, tree_for_NL102 ) else break # out of loop for decision 41 end end # loop for decision 41 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_state_dependency_666 ) constraint_body103 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body103.tree ) char_literal104 = match( T__21, TOKENS_FOLLOWING_T__21_IN_state_dependency_670 ) tree_for_char_literal104 = @adaptor.create_with_payload( char_literal104 ) @adaptor.add_child( root_0, tree_for_char_literal104 ) else break # out of loop for decision 42 end end # loop for decision 42 # at file 290:3: ( NL )+ match_count_43 = 0 while true alt_43 = 2 look_43_0 = @input.peek( 1 ) if ( look_43_0 == NL ) alt_43 = 1 end case alt_43 when 1 # at line 290:3: NL __NL105__ = match( NL, TOKENS_FOLLOWING_NL_IN_state_dependency_676 ) tree_for_NL105 = @adaptor.create_with_payload( __NL105__ ) @adaptor.add_child( root_0, tree_for_NL105 ) else match_count_43 > 0 and break eee = EarlyExit(43) raise eee end match_count_43 += 1 end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 17 ) end return return_value end DepEffectReturnValue = define_return_scope # # parser rule dep_effect # # (in SfpLang.g) # 293:1: dep_effect : reference equals_op ( value | NULL ) ; # def dep_effect # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 18 ) return_value = DepEffectReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NULL109__ = nil reference106 = nil equals_op107 = nil value108 = nil tree_for_NULL109 = nil begin root_0 = @adaptor.create_flat_list # at line 294:4: reference equals_op ( value | NULL ) @state.following.push( TOKENS_FOLLOWING_reference_IN_dep_effect_688 ) reference106 = reference @state.following.pop @adaptor.add_child( root_0, reference106.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_dep_effect_690 ) equals_op107 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op107.tree ) # at line 295:3: ( value | NULL ) alt_44 = 2 look_44_0 = @input.peek( 1 ) if ( look_44_0.between?( STRING, NUMBER ) || look_44_0.between?( BOOLEAN, MULTILINE_STRING ) || look_44_0 == T__41 || look_44_0 == T__72 ) alt_44 = 1 elsif ( look_44_0 == NULL ) alt_44 = 2 else raise NoViableAlternative( "", 44, 0 ) end case alt_44 when 1 # at line 295:5: value @state.following.push( TOKENS_FOLLOWING_value_IN_dep_effect_697 ) value108 = value @state.following.pop @adaptor.add_child( root_0, value108.tree ) when 2 # at line 296:5: NULL __NULL109__ = match( NULL, TOKENS_FOLLOWING_NULL_IN_dep_effect_703 ) tree_for_NULL109 = @adaptor.create_with_payload( __NULL109__ ) @adaptor.add_child( root_0, tree_for_NULL109 ) end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 18 ) end return return_value end OpParamReturnValue = define_return_scope # # parser rule op_param # # (in SfpLang.g) # 300:1: op_param : ID equals_op reference ( NL )+ ; # def op_param # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 19 ) return_value = OpParamReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID110__ = nil __NL113__ = nil equals_op111 = nil reference112 = nil tree_for_ID110 = nil tree_for_NL113 = nil begin root_0 = @adaptor.create_flat_list # at line 301:4: ID equals_op reference ( NL )+ __ID110__ = match( ID, TOKENS_FOLLOWING_ID_IN_op_param_719 ) tree_for_ID110 = @adaptor.create_with_payload( __ID110__ ) @adaptor.add_child( root_0, tree_for_ID110 ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_op_param_721 ) equals_op111 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op111.tree ) @state.following.push( TOKENS_FOLLOWING_reference_IN_op_param_723 ) reference112 = reference @state.following.pop @adaptor.add_child( root_0, reference112.tree ) # at file 301:27: ( NL )+ match_count_45 = 0 while true alt_45 = 2 look_45_0 = @input.peek( 1 ) if ( look_45_0 == NL ) alt_45 = 1 end case alt_45 when 1 # at line 301:27: NL __NL113__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_param_725 ) tree_for_NL113 = @adaptor.create_with_payload( __NL113__ ) @adaptor.add_child( root_0, tree_for_NL113 ) else match_count_45 > 0 and break eee = EarlyExit(45) raise eee end match_count_45 += 1 end # --> action @now[__ID110__.text] = ( reference112.nil? ? nil : reference112.val ) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 19 ) end return return_value end OpConditionsReturnValue = define_return_scope # # parser rule op_conditions # # (in SfpLang.g) # 305:1: op_conditions : ( 'conditions' | 'condition' ) '{' ( NL )* ( op_statement )* '}' ( NL )+ ; # def op_conditions # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 20 ) return_value = OpConditionsReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set114 = nil char_literal115 = nil __NL116__ = nil char_literal118 = nil __NL119__ = nil op_statement117 = nil tree_for_set114 = nil tree_for_char_literal115 = nil tree_for_NL116 = nil tree_for_char_literal118 = nil tree_for_NL119 = nil begin root_0 = @adaptor.create_flat_list # at line 306:4: ( 'conditions' | 'condition' ) '{' ( NL )* ( op_statement )* '}' ( NL )+ set114 = @input.look if @input.peek( 1 ).between?( T__35, T__36 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set114 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end char_literal115 = match( T__20, TOKENS_FOLLOWING_T__20_IN_op_conditions_749 ) tree_for_char_literal115 = @adaptor.create_with_payload( char_literal115 ) @adaptor.add_child( root_0, tree_for_char_literal115 ) # at line 306:37: ( NL )* while true # decision 46 alt_46 = 2 look_46_0 = @input.peek( 1 ) if ( look_46_0 == NL ) alt_46 = 1 end case alt_46 when 1 # at line 306:37: NL __NL116__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_conditions_751 ) tree_for_NL116 = @adaptor.create_with_payload( __NL116__ ) @adaptor.add_child( root_0, tree_for_NL116 ) else break # out of loop for decision 46 end end # loop for decision 46 # --> action @now['_condition']['_parent'] = @now @now = @now['_condition'] # <-- action # at line 311:3: ( op_statement )* while true # decision 47 alt_47 = 2 look_47_0 = @input.peek( 1 ) if ( look_47_0 == ID ) alt_47 = 1 end case alt_47 when 1 # at line 311:3: op_statement @state.following.push( TOKENS_FOLLOWING_op_statement_IN_op_conditions_760 ) op_statement117 = op_statement @state.following.pop @adaptor.add_child( root_0, op_statement117.tree ) else break # out of loop for decision 47 end end # loop for decision 47 char_literal118 = match( T__21, TOKENS_FOLLOWING_T__21_IN_op_conditions_765 ) tree_for_char_literal118 = @adaptor.create_with_payload( char_literal118 ) @adaptor.add_child( root_0, tree_for_char_literal118 ) # at file 312:7: ( NL )+ match_count_48 = 0 while true alt_48 = 2 look_48_0 = @input.peek( 1 ) if ( look_48_0 == NL ) alt_48 = 1 end case alt_48 when 1 # at line 312:7: NL __NL119__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_conditions_767 ) tree_for_NL119 = @adaptor.create_with_payload( __NL119__ ) @adaptor.add_child( root_0, tree_for_NL119 ) else match_count_48 > 0 and break eee = EarlyExit(48) raise eee end match_count_48 += 1 end # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 20 ) end return return_value end OpEffectsReturnValue = define_return_scope # # parser rule op_effects # # (in SfpLang.g) # 316:1: op_effects : 'effects' '{' ( NL )* ( op_statement )* '}' ( NL )+ ; # def op_effects # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 21 ) return_value = OpEffectsReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal120 = nil char_literal121 = nil __NL122__ = nil char_literal124 = nil __NL125__ = nil op_statement123 = nil tree_for_string_literal120 = nil tree_for_char_literal121 = nil tree_for_NL122 = nil tree_for_char_literal124 = nil tree_for_NL125 = nil begin root_0 = @adaptor.create_flat_list # at line 317:4: 'effects' '{' ( NL )* ( op_statement )* '}' ( NL )+ string_literal120 = match( T__37, TOKENS_FOLLOWING_T__37_IN_op_effects_783 ) tree_for_string_literal120 = @adaptor.create_with_payload( string_literal120 ) @adaptor.add_child( root_0, tree_for_string_literal120 ) char_literal121 = match( T__20, TOKENS_FOLLOWING_T__20_IN_op_effects_785 ) tree_for_char_literal121 = @adaptor.create_with_payload( char_literal121 ) @adaptor.add_child( root_0, tree_for_char_literal121 ) # at line 317:18: ( NL )* while true # decision 49 alt_49 = 2 look_49_0 = @input.peek( 1 ) if ( look_49_0 == NL ) alt_49 = 1 end case alt_49 when 1 # at line 317:18: NL __NL122__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_effects_787 ) tree_for_NL122 = @adaptor.create_with_payload( __NL122__ ) @adaptor.add_child( root_0, tree_for_NL122 ) else break # out of loop for decision 49 end end # loop for decision 49 # --> action @now['_effect']['_parent'] = @now @now = @now['_effect'] # <-- action # at line 322:3: ( op_statement )* while true # decision 50 alt_50 = 2 look_50_0 = @input.peek( 1 ) if ( look_50_0 == ID ) alt_50 = 1 end case alt_50 when 1 # at line 322:3: op_statement @state.following.push( TOKENS_FOLLOWING_op_statement_IN_op_effects_796 ) op_statement123 = op_statement @state.following.pop @adaptor.add_child( root_0, op_statement123.tree ) else break # out of loop for decision 50 end end # loop for decision 50 char_literal124 = match( T__21, TOKENS_FOLLOWING_T__21_IN_op_effects_801 ) tree_for_char_literal124 = @adaptor.create_with_payload( char_literal124 ) @adaptor.add_child( root_0, tree_for_char_literal124 ) # at file 323:7: ( NL )+ match_count_51 = 0 while true alt_51 = 2 look_51_0 = @input.peek( 1 ) if ( look_51_0 == NL ) alt_51 = 1 end case alt_51 when 1 # at line 323:7: NL __NL125__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_effects_803 ) tree_for_NL125 = @adaptor.create_with_payload( __NL125__ ) @adaptor.add_child( root_0, tree_for_NL125 ) else match_count_51 > 0 and break eee = EarlyExit(51) raise eee end match_count_51 += 1 end # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 21 ) end return return_value end OpStatementReturnValue = define_return_scope # # parser rule op_statement # # (in SfpLang.g) # 327:1: op_statement : reference equals_op value ( NL )+ ; # def op_statement # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 22 ) return_value = OpStatementReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL129__ = nil reference126 = nil equals_op127 = nil value128 = nil tree_for_NL129 = nil begin root_0 = @adaptor.create_flat_list # at line 328:4: reference equals_op value ( NL )+ @state.following.push( TOKENS_FOLLOWING_reference_IN_op_statement_819 ) reference126 = reference @state.following.pop @adaptor.add_child( root_0, reference126.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_op_statement_821 ) equals_op127 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op127.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_op_statement_823 ) value128 = value @state.following.pop @adaptor.add_child( root_0, value128.tree ) # at file 328:30: ( NL )+ match_count_52 = 0 while true alt_52 = 2 look_52_0 = @input.peek( 1 ) if ( look_52_0 == NL ) alt_52 = 1 end case alt_52 when 1 # at line 328:30: NL __NL129__ = match( NL, TOKENS_FOLLOWING_NL_IN_op_statement_825 ) tree_for_NL129 = @adaptor.create_with_payload( __NL129__ ) @adaptor.add_child( root_0, tree_for_NL129 ) else match_count_52 > 0 and break eee = EarlyExit(52) raise eee end match_count_52 += 1 end # --> action @now[( reference126.nil? ? nil : reference126.val )] = ( value128.nil? ? nil : value128.val ) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 22 ) end return return_value end ProcedureReturnValue = define_return_scope # # parser rule procedure # # (in SfpLang.g) # 332:1: procedure : ( 'procedure' | 'sub' ) ID ( parameters )? '{' ( NL )* ( 'cost' equals_op NUMBER ( NL )+ )? ( conditions )? effects '}' ( NL )+ ; # def procedure # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 23 ) return_value = ProcedureReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set130 = nil __ID131__ = nil char_literal133 = nil __NL134__ = nil string_literal135 = nil __NUMBER137__ = nil __NL138__ = nil char_literal141 = nil __NL142__ = nil parameters132 = nil equals_op136 = nil conditions139 = nil effects140 = nil tree_for_set130 = nil tree_for_ID131 = nil tree_for_char_literal133 = nil tree_for_NL134 = nil tree_for_string_literal135 = nil tree_for_NUMBER137 = nil tree_for_NL138 = nil tree_for_char_literal141 = nil tree_for_NL142 = nil begin root_0 = @adaptor.create_flat_list # at line 333:4: ( 'procedure' | 'sub' ) ID ( parameters )? '{' ( NL )* ( 'cost' equals_op NUMBER ( NL )+ )? ( conditions )? effects '}' ( NL )+ set130 = @input.look if @input.peek( 1 ).between?( T__38, T__39 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set130 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end __ID131__ = match( ID, TOKENS_FOLLOWING_ID_IN_procedure_847 ) tree_for_ID131 = @adaptor.create_with_payload( __ID131__ ) @adaptor.add_child( root_0, tree_for_ID131 ) # --> action @now[__ID131__.text] = { '_self' => __ID131__.text, '_context' => 'procedure', '_parent' => @now, '_cost' => 1, '_condition' => { '_context' => 'constraint', '_type' => 'and' }, '_effect' => { '_context' => 'effect', '_type' => 'and' } } @now = @now[__ID131__.text] # <-- action # at line 344:3: ( parameters )? alt_53 = 2 look_53_0 = @input.peek( 1 ) if ( look_53_0 == T__41 ) alt_53 = 1 end case alt_53 when 1 # at line 344:3: parameters @state.following.push( TOKENS_FOLLOWING_parameters_IN_procedure_855 ) parameters132 = parameters @state.following.pop @adaptor.add_child( root_0, parameters132.tree ) end char_literal133 = match( T__20, TOKENS_FOLLOWING_T__20_IN_procedure_858 ) tree_for_char_literal133 = @adaptor.create_with_payload( char_literal133 ) @adaptor.add_child( root_0, tree_for_char_literal133 ) # at line 344:19: ( NL )* while true # decision 54 alt_54 = 2 look_54_0 = @input.peek( 1 ) if ( look_54_0 == NL ) alt_54 = 1 end case alt_54 when 1 # at line 344:19: NL __NL134__ = match( NL, TOKENS_FOLLOWING_NL_IN_procedure_860 ) tree_for_NL134 = @adaptor.create_with_payload( __NL134__ ) @adaptor.add_child( root_0, tree_for_NL134 ) else break # out of loop for decision 54 end end # loop for decision 54 # at line 345:3: ( 'cost' equals_op NUMBER ( NL )+ )? alt_56 = 2 look_56_0 = @input.peek( 1 ) if ( look_56_0 == T__40 ) alt_56 = 1 end case alt_56 when 1 # at line 345:5: 'cost' equals_op NUMBER ( NL )+ string_literal135 = match( T__40, TOKENS_FOLLOWING_T__40_IN_procedure_868 ) tree_for_string_literal135 = @adaptor.create_with_payload( string_literal135 ) @adaptor.add_child( root_0, tree_for_string_literal135 ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_procedure_870 ) equals_op136 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op136.tree ) __NUMBER137__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_procedure_872 ) tree_for_NUMBER137 = @adaptor.create_with_payload( __NUMBER137__ ) @adaptor.add_child( root_0, tree_for_NUMBER137 ) # --> action @now['_cost'] = __NUMBER137__.text.to_i # <-- action # at file 347:4: ( NL )+ match_count_55 = 0 while true alt_55 = 2 look_55_0 = @input.peek( 1 ) if ( look_55_0 == NL ) alt_55 = 1 end case alt_55 when 1 # at line 347:4: NL __NL138__ = match( NL, TOKENS_FOLLOWING_NL_IN_procedure_882 ) tree_for_NL138 = @adaptor.create_with_payload( __NL138__ ) @adaptor.add_child( root_0, tree_for_NL138 ) else match_count_55 > 0 and break eee = EarlyExit(55) raise eee end match_count_55 += 1 end end # at line 349:3: ( conditions )? alt_57 = 2 look_57_0 = @input.peek( 1 ) if ( look_57_0.between?( T__35, T__36 ) ) alt_57 = 1 end case alt_57 when 1 # at line 349:3: conditions @state.following.push( TOKENS_FOLLOWING_conditions_IN_procedure_892 ) conditions139 = conditions @state.following.pop @adaptor.add_child( root_0, conditions139.tree ) end @state.following.push( TOKENS_FOLLOWING_effects_IN_procedure_895 ) effects140 = effects @state.following.pop @adaptor.add_child( root_0, effects140.tree ) char_literal141 = match( T__21, TOKENS_FOLLOWING_T__21_IN_procedure_897 ) tree_for_char_literal141 = @adaptor.create_with_payload( char_literal141 ) @adaptor.add_child( root_0, tree_for_char_literal141 ) # at file 349:27: ( NL )+ match_count_58 = 0 while true alt_58 = 2 look_58_0 = @input.peek( 1 ) if ( look_58_0 == NL ) alt_58 = 1 end case alt_58 when 1 # at line 349:27: NL __NL142__ = match( NL, TOKENS_FOLLOWING_NL_IN_procedure_899 ) tree_for_NL142 = @adaptor.create_with_payload( __NL142__ ) @adaptor.add_child( root_0, tree_for_NL142 ) else match_count_58 > 0 and break eee = EarlyExit(58) raise eee end match_count_58 += 1 end # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 23 ) end return return_value end ParametersReturnValue = define_return_scope # # parser rule parameters # # (in SfpLang.g) # 353:1: parameters : '(' parameter ( ',' ( NL )* parameter )* ')' ; # def parameters # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 24 ) return_value = ParametersReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal143 = nil char_literal145 = nil __NL146__ = nil char_literal148 = nil parameter144 = nil parameter147 = nil tree_for_char_literal143 = nil tree_for_char_literal145 = nil tree_for_NL146 = nil tree_for_char_literal148 = nil begin root_0 = @adaptor.create_flat_list # at line 354:4: '(' parameter ( ',' ( NL )* parameter )* ')' char_literal143 = match( T__41, TOKENS_FOLLOWING_T__41_IN_parameters_915 ) tree_for_char_literal143 = @adaptor.create_with_payload( char_literal143 ) @adaptor.add_child( root_0, tree_for_char_literal143 ) @state.following.push( TOKENS_FOLLOWING_parameter_IN_parameters_917 ) parameter144 = parameter @state.following.pop @adaptor.add_child( root_0, parameter144.tree ) # at line 354:18: ( ',' ( NL )* parameter )* while true # decision 60 alt_60 = 2 look_60_0 = @input.peek( 1 ) if ( look_60_0 == T__30 ) alt_60 = 1 end case alt_60 when 1 # at line 354:19: ',' ( NL )* parameter char_literal145 = match( T__30, TOKENS_FOLLOWING_T__30_IN_parameters_920 ) tree_for_char_literal145 = @adaptor.create_with_payload( char_literal145 ) @adaptor.add_child( root_0, tree_for_char_literal145 ) # at line 354:23: ( NL )* while true # decision 59 alt_59 = 2 look_59_0 = @input.peek( 1 ) if ( look_59_0 == NL ) alt_59 = 1 end case alt_59 when 1 # at line 354:23: NL __NL146__ = match( NL, TOKENS_FOLLOWING_NL_IN_parameters_922 ) tree_for_NL146 = @adaptor.create_with_payload( __NL146__ ) @adaptor.add_child( root_0, tree_for_NL146 ) else break # out of loop for decision 59 end end # loop for decision 59 @state.following.push( TOKENS_FOLLOWING_parameter_IN_parameters_925 ) parameter147 = parameter @state.following.pop @adaptor.add_child( root_0, parameter147.tree ) else break # out of loop for decision 60 end end # loop for decision 60 char_literal148 = match( T__42, TOKENS_FOLLOWING_T__42_IN_parameters_929 ) tree_for_char_literal148 = @adaptor.create_with_payload( char_literal148 ) @adaptor.add_child( root_0, tree_for_char_literal148 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 24 ) end return return_value end ParameterReturnValue = define_return_scope # # parser rule parameter # # (in SfpLang.g) # 357:1: parameter : ( ID ':' path | ID reference_type | ID 'areall' path | ID 'isset' path ); # def parameter # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 25 ) return_value = ParameterReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID149__ = nil char_literal150 = nil __ID152__ = nil __ID154__ = nil string_literal155 = nil __ID157__ = nil string_literal158 = nil path151 = nil reference_type153 = nil path156 = nil path159 = nil tree_for_ID149 = nil tree_for_char_literal150 = nil tree_for_ID152 = nil tree_for_ID154 = nil tree_for_string_literal155 = nil tree_for_ID157 = nil tree_for_string_literal158 = nil begin # at line 358:2: ( ID ':' path | ID reference_type | ID 'areall' path | ID 'isset' path ) alt_61 = 4 look_61_0 = @input.peek( 1 ) if ( look_61_0 == ID ) case look_61 = @input.peek( 2 ) when T__27 then alt_61 = 1 when T__43 then alt_61 = 3 when T__44 then alt_61 = 4 when T__74 then alt_61 = 2 else raise NoViableAlternative( "", 61, 1 ) end else raise NoViableAlternative( "", 61, 0 ) end case alt_61 when 1 root_0 = @adaptor.create_flat_list # at line 358:4: ID ':' path __ID149__ = match( ID, TOKENS_FOLLOWING_ID_IN_parameter_941 ) tree_for_ID149 = @adaptor.create_with_payload( __ID149__ ) @adaptor.add_child( root_0, tree_for_ID149 ) char_literal150 = match( T__27, TOKENS_FOLLOWING_T__27_IN_parameter_943 ) tree_for_char_literal150 = @adaptor.create_with_payload( char_literal150 ) @adaptor.add_child( root_0, tree_for_char_literal150 ) @state.following.push( TOKENS_FOLLOWING_path_IN_parameter_945 ) path151 = path @state.following.pop @adaptor.add_child( root_0, path151.tree ) # --> action @now[__ID149__.text] = { '_context' => 'any_value', '_isa' => self.to_ref(( path151 && @input.to_s( path151.start, path151.stop ) )) } # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 364:4: ID reference_type __ID152__ = match( ID, TOKENS_FOLLOWING_ID_IN_parameter_954 ) tree_for_ID152 = @adaptor.create_with_payload( __ID152__ ) @adaptor.add_child( root_0, tree_for_ID152 ) @state.following.push( TOKENS_FOLLOWING_reference_type_IN_parameter_956 ) reference_type153 = reference_type @state.following.pop @adaptor.add_child( root_0, reference_type153.tree ) # --> action @now[__ID152__.text] = ( reference_type153.nil? ? nil : reference_type153.val ) # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 366:4: ID 'areall' path __ID154__ = match( ID, TOKENS_FOLLOWING_ID_IN_parameter_965 ) tree_for_ID154 = @adaptor.create_with_payload( __ID154__ ) @adaptor.add_child( root_0, tree_for_ID154 ) string_literal155 = match( T__43, TOKENS_FOLLOWING_T__43_IN_parameter_967 ) tree_for_string_literal155 = @adaptor.create_with_payload( string_literal155 ) @adaptor.add_child( root_0, tree_for_string_literal155 ) @state.following.push( TOKENS_FOLLOWING_path_IN_parameter_969 ) path156 = path @state.following.pop @adaptor.add_child( root_0, path156.tree ) # --> action @now[__ID154__.text] = { '_context' => 'all', '_isa' => self.to_ref(( path156 && @input.to_s( path156.start, path156.stop ) )), '_value' => nil } # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 373:4: ID 'isset' path __ID157__ = match( ID, TOKENS_FOLLOWING_ID_IN_parameter_978 ) tree_for_ID157 = @adaptor.create_with_payload( __ID157__ ) @adaptor.add_child( root_0, tree_for_ID157 ) string_literal158 = match( T__44, TOKENS_FOLLOWING_T__44_IN_parameter_980 ) tree_for_string_literal158 = @adaptor.create_with_payload( string_literal158 ) @adaptor.add_child( root_0, tree_for_string_literal158 ) @state.following.push( TOKENS_FOLLOWING_path_IN_parameter_982 ) path159 = path @state.following.pop @adaptor.add_child( root_0, path159.tree ) # --> action @now[__ID157__.text] = { '_context' => 'set', '_isa' => self.to_ref(( path159 && @input.to_s( path159.start, path159.stop ) )), '_values' => [] } # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 25 ) end return return_value end ConditionsReturnValue = define_return_scope # # parser rule conditions # # (in SfpLang.g) # 382:1: conditions : ( 'conditions' | 'condition' ) '{' ( NL )* constraint_body '}' ( NL )+ ; # def conditions # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 26 ) return_value = ConditionsReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set160 = nil char_literal161 = nil __NL162__ = nil char_literal164 = nil __NL165__ = nil constraint_body163 = nil tree_for_set160 = nil tree_for_char_literal161 = nil tree_for_NL162 = nil tree_for_char_literal164 = nil tree_for_NL165 = nil begin root_0 = @adaptor.create_flat_list # at line 383:4: ( 'conditions' | 'condition' ) '{' ( NL )* constraint_body '}' ( NL )+ set160 = @input.look if @input.peek( 1 ).between?( T__35, T__36 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set160 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # --> action @now['_condition']['_parent'] = @now @now = @now['_condition'] # <-- action char_literal161 = match( T__20, TOKENS_FOLLOWING_T__20_IN_conditions_1011 ) tree_for_char_literal161 = @adaptor.create_with_payload( char_literal161 ) @adaptor.add_child( root_0, tree_for_char_literal161 ) # at line 388:7: ( NL )* while true # decision 62 alt_62 = 2 look_62_0 = @input.peek( 1 ) if ( look_62_0 == NL ) alt_62 = 1 end case alt_62 when 1 # at line 388:7: NL __NL162__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditions_1013 ) tree_for_NL162 = @adaptor.create_with_payload( __NL162__ ) @adaptor.add_child( root_0, tree_for_NL162 ) else break # out of loop for decision 62 end end # loop for decision 62 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_conditions_1016 ) constraint_body163 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body163.tree ) char_literal164 = match( T__21, TOKENS_FOLLOWING_T__21_IN_conditions_1018 ) tree_for_char_literal164 = @adaptor.create_with_payload( char_literal164 ) @adaptor.add_child( root_0, tree_for_char_literal164 ) # at file 388:31: ( NL )+ match_count_63 = 0 while true alt_63 = 2 look_63_0 = @input.peek( 1 ) if ( look_63_0 == NL ) alt_63 = 1 end case alt_63 when 1 # at line 388:31: NL __NL165__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditions_1020 ) tree_for_NL165 = @adaptor.create_with_payload( __NL165__ ) @adaptor.add_child( root_0, tree_for_NL165 ) else match_count_63 > 0 and break eee = EarlyExit(63) raise eee end match_count_63 += 1 end # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 26 ) end return return_value end EffectsReturnValue = define_return_scope # # parser rule effects # # (in SfpLang.g) # 393:1: effects : ( 'effects' | 'effect' ) '{' ( NL )* effect_body '}' ( NL )+ ; # def effects # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 27 ) return_value = EffectsReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set166 = nil char_literal167 = nil __NL168__ = nil char_literal170 = nil __NL171__ = nil effect_body169 = nil tree_for_set166 = nil tree_for_char_literal167 = nil tree_for_NL168 = nil tree_for_char_literal170 = nil tree_for_NL171 = nil begin root_0 = @adaptor.create_flat_list # at line 394:4: ( 'effects' | 'effect' ) '{' ( NL )* effect_body '}' ( NL )+ set166 = @input.look if @input.peek(1) == T__37 || @input.peek(1) == T__45 @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set166 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # --> action @now['_effect']['_parent'] = @now @now = @now['_effect'] @in_effects = true # <-- action char_literal167 = match( T__20, TOKENS_FOLLOWING_T__20_IN_effects_1051 ) tree_for_char_literal167 = @adaptor.create_with_payload( char_literal167 ) @adaptor.add_child( root_0, tree_for_char_literal167 ) # at line 400:7: ( NL )* while true # decision 64 alt_64 = 2 look_64_0 = @input.peek( 1 ) if ( look_64_0 == NL ) alt_64 = 1 end case alt_64 when 1 # at line 400:7: NL __NL168__ = match( NL, TOKENS_FOLLOWING_NL_IN_effects_1053 ) tree_for_NL168 = @adaptor.create_with_payload( __NL168__ ) @adaptor.add_child( root_0, tree_for_NL168 ) else break # out of loop for decision 64 end end # loop for decision 64 @state.following.push( TOKENS_FOLLOWING_effect_body_IN_effects_1059 ) effect_body169 = effect_body @state.following.pop @adaptor.add_child( root_0, effect_body169.tree ) char_literal170 = match( T__21, TOKENS_FOLLOWING_T__21_IN_effects_1064 ) tree_for_char_literal170 = @adaptor.create_with_payload( char_literal170 ) @adaptor.add_child( root_0, tree_for_char_literal170 ) # at file 402:7: ( NL )+ match_count_65 = 0 while true alt_65 = 2 look_65_0 = @input.peek( 1 ) if ( look_65_0 == NL ) alt_65 = 1 end case alt_65 when 1 # at line 402:7: NL __NL171__ = match( NL, TOKENS_FOLLOWING_NL_IN_effects_1066 ) tree_for_NL171 = @adaptor.create_with_payload( __NL171__ ) @adaptor.add_child( root_0, tree_for_NL171 ) else match_count_65 > 0 and break eee = EarlyExit(65) raise eee end match_count_65 += 1 end # --> action self.goto_parent() @in_effects = false # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 27 ) end return return_value end GoalConstraintReturnValue = define_return_scope # # parser rule goal_constraint # # (in SfpLang.g) # 409:1: goal_constraint : 'goal' ( 'constraint' )? ( NL )* '{' ( NL )* ( goal_body )* '}' ; # def goal_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 28 ) return_value = GoalConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal172 = nil string_literal173 = nil __NL174__ = nil char_literal175 = nil __NL176__ = nil char_literal178 = nil goal_body177 = nil tree_for_string_literal172 = nil tree_for_string_literal173 = nil tree_for_NL174 = nil tree_for_char_literal175 = nil tree_for_NL176 = nil tree_for_char_literal178 = nil begin root_0 = @adaptor.create_flat_list # at line 410:4: 'goal' ( 'constraint' )? ( NL )* '{' ( NL )* ( goal_body )* '}' string_literal172 = match( T__46, TOKENS_FOLLOWING_T__46_IN_goal_constraint_1082 ) tree_for_string_literal172 = @adaptor.create_with_payload( string_literal172 ) @adaptor.add_child( root_0, tree_for_string_literal172 ) # at line 410:11: ( 'constraint' )? alt_66 = 2 look_66_0 = @input.peek( 1 ) if ( look_66_0 == T__47 ) alt_66 = 1 end case alt_66 when 1 # at line 410:11: 'constraint' string_literal173 = match( T__47, TOKENS_FOLLOWING_T__47_IN_goal_constraint_1084 ) tree_for_string_literal173 = @adaptor.create_with_payload( string_literal173 ) @adaptor.add_child( root_0, tree_for_string_literal173 ) end # at line 410:25: ( NL )* while true # decision 67 alt_67 = 2 look_67_0 = @input.peek( 1 ) if ( look_67_0 == NL ) alt_67 = 1 end case alt_67 when 1 # at line 410:25: NL __NL174__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_constraint_1087 ) tree_for_NL174 = @adaptor.create_with_payload( __NL174__ ) @adaptor.add_child( root_0, tree_for_NL174 ) else break # out of loop for decision 67 end end # loop for decision 67 # --> action @now['goal'] = { '_self' => 'goal', '_context' => 'constraint', '_type' => 'and', '_parent' => @now } @now = @now['goal'] # <-- action char_literal175 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_constraint_1096 ) tree_for_char_literal175 = @adaptor.create_with_payload( char_literal175 ) @adaptor.add_child( root_0, tree_for_char_literal175 ) # at line 419:7: ( NL )* while true # decision 68 alt_68 = 2 look_68_0 = @input.peek( 1 ) if ( look_68_0 == NL ) alt_68 = 1 end case alt_68 when 1 # at line 419:7: NL __NL176__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_constraint_1098 ) tree_for_NL176 = @adaptor.create_with_payload( __NL176__ ) @adaptor.add_child( root_0, tree_for_NL176 ) else break # out of loop for decision 68 end end # loop for decision 68 # at line 419:11: ( goal_body )* while true # decision 69 alt_69 = 2 look_69_0 = @input.peek( 1 ) if ( look_69_0 == ID || look_69_0 == T__32 || look_69_0.between?( T__48, T__54 ) || look_69_0.between?( T__56, T__58 ) || look_69_0 == T__61 || look_69_0 == T__67 ) alt_69 = 1 end case alt_69 when 1 # at line 419:11: goal_body @state.following.push( TOKENS_FOLLOWING_goal_body_IN_goal_constraint_1101 ) goal_body177 = goal_body @state.following.pop @adaptor.add_child( root_0, goal_body177.tree ) else break # out of loop for decision 69 end end # loop for decision 69 char_literal178 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_constraint_1104 ) tree_for_char_literal178 = @adaptor.create_with_payload( char_literal178 ) @adaptor.add_child( root_0, tree_for_char_literal178 ) # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 28 ) end return return_value end GlobalConstraintReturnValue = define_return_scope # # parser rule global_constraint # # (in SfpLang.g) # 423:1: global_constraint : ( 'global' | 'always' ) ( 'constraint' )? ( NL )* '{' ( NL )* constraint_body '}' ; # def global_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 29 ) return_value = GlobalConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set179 = nil string_literal180 = nil __NL181__ = nil char_literal182 = nil __NL183__ = nil char_literal185 = nil constraint_body184 = nil tree_for_set179 = nil tree_for_string_literal180 = nil tree_for_NL181 = nil tree_for_char_literal182 = nil tree_for_NL183 = nil tree_for_char_literal185 = nil begin root_0 = @adaptor.create_flat_list # at line 424:4: ( 'global' | 'always' ) ( 'constraint' )? ( NL )* '{' ( NL )* constraint_body '}' set179 = @input.look if @input.peek( 1 ).between?( T__48, T__49 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set179 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # at line 424:24: ( 'constraint' )? alt_70 = 2 look_70_0 = @input.peek( 1 ) if ( look_70_0 == T__47 ) alt_70 = 1 end case alt_70 when 1 # at line 424:24: 'constraint' string_literal180 = match( T__47, TOKENS_FOLLOWING_T__47_IN_global_constraint_1125 ) tree_for_string_literal180 = @adaptor.create_with_payload( string_literal180 ) @adaptor.add_child( root_0, tree_for_string_literal180 ) end # at line 424:38: ( NL )* while true # decision 71 alt_71 = 2 look_71_0 = @input.peek( 1 ) if ( look_71_0 == NL ) alt_71 = 1 end case alt_71 when 1 # at line 424:38: NL __NL181__ = match( NL, TOKENS_FOLLOWING_NL_IN_global_constraint_1128 ) tree_for_NL181 = @adaptor.create_with_payload( __NL181__ ) @adaptor.add_child( root_0, tree_for_NL181 ) else break # out of loop for decision 71 end end # loop for decision 71 # --> action @now['global'] = self.create_constraint('global', 'and') if !@now.has_key?('global') @now = @now['global'] # <-- action char_literal182 = match( T__20, TOKENS_FOLLOWING_T__20_IN_global_constraint_1137 ) tree_for_char_literal182 = @adaptor.create_with_payload( char_literal182 ) @adaptor.add_child( root_0, tree_for_char_literal182 ) # at line 429:7: ( NL )* while true # decision 72 alt_72 = 2 look_72_0 = @input.peek( 1 ) if ( look_72_0 == NL ) alt_72 = 1 end case alt_72 when 1 # at line 429:7: NL __NL183__ = match( NL, TOKENS_FOLLOWING_NL_IN_global_constraint_1139 ) tree_for_NL183 = @adaptor.create_with_payload( __NL183__ ) @adaptor.add_child( root_0, tree_for_NL183 ) else break # out of loop for decision 72 end end # loop for decision 72 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_global_constraint_1142 ) constraint_body184 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body184.tree ) char_literal185 = match( T__21, TOKENS_FOLLOWING_T__21_IN_global_constraint_1144 ) tree_for_char_literal185 = @adaptor.create_with_payload( char_literal185 ) @adaptor.add_child( root_0, tree_for_char_literal185 ) # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 29 ) end return return_value end SometimeConstraintReturnValue = define_return_scope # # parser rule sometime_constraint # # (in SfpLang.g) # 433:1: sometime_constraint : 'sometime' ( 'constraint' )? ( NL )* '{' ( NL )* constraint_body '}' ; # def sometime_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 30 ) return_value = SometimeConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal186 = nil string_literal187 = nil __NL188__ = nil char_literal189 = nil __NL190__ = nil char_literal192 = nil constraint_body191 = nil tree_for_string_literal186 = nil tree_for_string_literal187 = nil tree_for_NL188 = nil tree_for_char_literal189 = nil tree_for_NL190 = nil tree_for_char_literal192 = nil begin root_0 = @adaptor.create_flat_list # at line 434:4: 'sometime' ( 'constraint' )? ( NL )* '{' ( NL )* constraint_body '}' string_literal186 = match( T__50, TOKENS_FOLLOWING_T__50_IN_sometime_constraint_1159 ) tree_for_string_literal186 = @adaptor.create_with_payload( string_literal186 ) @adaptor.add_child( root_0, tree_for_string_literal186 ) # at line 434:15: ( 'constraint' )? alt_73 = 2 look_73_0 = @input.peek( 1 ) if ( look_73_0 == T__47 ) alt_73 = 1 end case alt_73 when 1 # at line 434:15: 'constraint' string_literal187 = match( T__47, TOKENS_FOLLOWING_T__47_IN_sometime_constraint_1161 ) tree_for_string_literal187 = @adaptor.create_with_payload( string_literal187 ) @adaptor.add_child( root_0, tree_for_string_literal187 ) end # at line 434:29: ( NL )* while true # decision 74 alt_74 = 2 look_74_0 = @input.peek( 1 ) if ( look_74_0 == NL ) alt_74 = 1 end case alt_74 when 1 # at line 434:29: NL __NL188__ = match( NL, TOKENS_FOLLOWING_NL_IN_sometime_constraint_1164 ) tree_for_NL188 = @adaptor.create_with_payload( __NL188__ ) @adaptor.add_child( root_0, tree_for_NL188 ) else break # out of loop for decision 74 end end # loop for decision 74 # --> action @now['sometime'] = self.create_constraint('sometime', 'or') if !@now.has_key?('sometime') @now = @now['sometime'] # <-- action char_literal189 = match( T__20, TOKENS_FOLLOWING_T__20_IN_sometime_constraint_1173 ) tree_for_char_literal189 = @adaptor.create_with_payload( char_literal189 ) @adaptor.add_child( root_0, tree_for_char_literal189 ) # at line 439:7: ( NL )* while true # decision 75 alt_75 = 2 look_75_0 = @input.peek( 1 ) if ( look_75_0 == NL ) alt_75 = 1 end case alt_75 when 1 # at line 439:7: NL __NL190__ = match( NL, TOKENS_FOLLOWING_NL_IN_sometime_constraint_1175 ) tree_for_NL190 = @adaptor.create_with_payload( __NL190__ ) @adaptor.add_child( root_0, tree_for_NL190 ) else break # out of loop for decision 75 end end # loop for decision 75 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_sometime_constraint_1178 ) constraint_body191 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body191.tree ) char_literal192 = match( T__21, TOKENS_FOLLOWING_T__21_IN_sometime_constraint_1180 ) tree_for_char_literal192 = @adaptor.create_with_payload( char_literal192 ) @adaptor.add_child( root_0, tree_for_char_literal192 ) # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 30 ) end return return_value end GoalBodyReturnValue = define_return_scope # # parser rule goal_body # # (in SfpLang.g) # 444:1: goal_body : ( ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ ) | ( 'always' | 'global' ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'sometime' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'within' NUMBER ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'after' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* ( 'then' | 'within' NUMBER ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'before' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* 'then' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ ); # def goal_body # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 31 ) return_value = GoalBodyReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL197__ = nil set198 = nil __NL199__ = nil char_literal200 = nil __NL201__ = nil char_literal203 = nil __NL204__ = nil string_literal205 = nil __NL206__ = nil char_literal207 = nil __NL208__ = nil char_literal210 = nil __NL211__ = nil string_literal212 = nil __NUMBER213__ = nil __NL214__ = nil char_literal215 = nil __NL216__ = nil char_literal218 = nil __NL219__ = nil string_literal220 = nil __NL221__ = nil char_literal222 = nil __NL223__ = nil char_literal225 = nil __NL226__ = nil string_literal227 = nil string_literal228 = nil __NUMBER229__ = nil __NL230__ = nil char_literal231 = nil __NL232__ = nil char_literal234 = nil __NL235__ = nil string_literal236 = nil __NL237__ = nil char_literal238 = nil __NL239__ = nil char_literal241 = nil __NL242__ = nil string_literal243 = nil __NL244__ = nil char_literal245 = nil __NL246__ = nil char_literal248 = nil __NL249__ = nil constraint_statement193 = nil constraint_namespace194 = nil constraint_iterator195 = nil constraint_class_quantification196 = nil constraint_body202 = nil constraint_body209 = nil constraint_body217 = nil constraint_body224 = nil constraint_body233 = nil constraint_body240 = nil constraint_body247 = nil tree_for_NL197 = nil tree_for_set198 = nil tree_for_NL199 = nil tree_for_char_literal200 = nil tree_for_NL201 = nil tree_for_char_literal203 = nil tree_for_NL204 = nil tree_for_string_literal205 = nil tree_for_NL206 = nil tree_for_char_literal207 = nil tree_for_NL208 = nil tree_for_char_literal210 = nil tree_for_NL211 = nil tree_for_string_literal212 = nil tree_for_NUMBER213 = nil tree_for_NL214 = nil tree_for_char_literal215 = nil tree_for_NL216 = nil tree_for_char_literal218 = nil tree_for_NL219 = nil tree_for_string_literal220 = nil tree_for_NL221 = nil tree_for_char_literal222 = nil tree_for_NL223 = nil tree_for_char_literal225 = nil tree_for_NL226 = nil tree_for_string_literal227 = nil tree_for_string_literal228 = nil tree_for_NUMBER229 = nil tree_for_NL230 = nil tree_for_char_literal231 = nil tree_for_NL232 = nil tree_for_char_literal234 = nil tree_for_NL235 = nil tree_for_string_literal236 = nil tree_for_NL237 = nil tree_for_char_literal238 = nil tree_for_NL239 = nil tree_for_char_literal241 = nil tree_for_NL242 = nil tree_for_string_literal243 = nil tree_for_NL244 = nil tree_for_char_literal245 = nil tree_for_NL246 = nil tree_for_char_literal248 = nil tree_for_NL249 = nil begin # at line 445:2: ( ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ ) | ( 'always' | 'global' ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'sometime' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'within' NUMBER ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'after' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* ( 'then' | 'within' NUMBER ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ | 'before' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* 'then' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ ) alt_100 = 6 case look_100 = @input.peek( 1 ) when ID, T__32, T__54, T__56, T__57, T__58, T__61, T__67 then alt_100 = 1 when T__48, T__49 then alt_100 = 2 when T__50 then alt_100 = 3 when T__51 then alt_100 = 4 when T__52 then alt_100 = 5 when T__53 then alt_100 = 6 else raise NoViableAlternative( "", 100, 0 ) end case alt_100 when 1 root_0 = @adaptor.create_flat_list # at line 445:4: ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ ) # at line 445:4: ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ ) # at line 446:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ # at line 446:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) alt_76 = 4 alt_76 = @dfa76.predict( @input ) case alt_76 when 1 # at line 446:6: constraint_statement @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_goal_body_1203 ) constraint_statement193 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement193.tree ) # --> action @now[( constraint_statement193.nil? ? nil : constraint_statement193.key )] = ( constraint_statement193.nil? ? nil : constraint_statement193.val ) # <-- action when 2 # at line 450:6: constraint_namespace @state.following.push( TOKENS_FOLLOWING_constraint_namespace_IN_goal_body_1216 ) constraint_namespace194 = constraint_namespace @state.following.pop @adaptor.add_child( root_0, constraint_namespace194.tree ) when 3 # at line 451:6: constraint_iterator @state.following.push( TOKENS_FOLLOWING_constraint_iterator_IN_goal_body_1223 ) constraint_iterator195 = constraint_iterator @state.following.pop @adaptor.add_child( root_0, constraint_iterator195.tree ) when 4 # at line 452:6: constraint_class_quantification @state.following.push( TOKENS_FOLLOWING_constraint_class_quantification_IN_goal_body_1230 ) constraint_class_quantification196 = constraint_class_quantification @state.following.pop @adaptor.add_child( root_0, constraint_class_quantification196.tree ) end # at file 454:3: ( NL )+ match_count_77 = 0 while true alt_77 = 2 look_77_0 = @input.peek( 1 ) if ( look_77_0 == NL ) alt_77 = 1 end case alt_77 when 1 # at line 454:3: NL __NL197__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1239 ) tree_for_NL197 = @adaptor.create_with_payload( __NL197__ ) @adaptor.add_child( root_0, tree_for_NL197 ) else match_count_77 > 0 and break eee = EarlyExit(77) raise eee end match_count_77 += 1 end when 2 root_0 = @adaptor.create_flat_list # at line 455:4: ( 'always' | 'global' ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ set198 = @input.look if @input.peek( 1 ).between?( T__48, T__49 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set198 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # at line 455:24: ( NL )* while true # decision 78 alt_78 = 2 look_78_0 = @input.peek( 1 ) if ( look_78_0 == NL ) alt_78 = 1 end case alt_78 when 1 # at line 455:24: NL __NL199__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1252 ) tree_for_NL199 = @adaptor.create_with_payload( __NL199__ ) @adaptor.add_child( root_0, tree_for_NL199 ) else break # out of loop for decision 78 end end # loop for decision 78 # --> action @now['global'] = self.create_constraint('global', 'and') if not @now.has_key?('global') @now = @now['global'] # <-- action char_literal200 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1261 ) tree_for_char_literal200 = @adaptor.create_with_payload( char_literal200 ) @adaptor.add_child( root_0, tree_for_char_literal200 ) # at line 461:7: ( NL )* while true # decision 79 alt_79 = 2 look_79_0 = @input.peek( 1 ) if ( look_79_0 == NL ) alt_79 = 1 end case alt_79 when 1 # at line 461:7: NL __NL201__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1263 ) tree_for_NL201 = @adaptor.create_with_payload( __NL201__ ) @adaptor.add_child( root_0, tree_for_NL201 ) else break # out of loop for decision 79 end end # loop for decision 79 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1266 ) constraint_body202 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body202.tree ) char_literal203 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1268 ) tree_for_char_literal203 = @adaptor.create_with_payload( char_literal203 ) @adaptor.add_child( root_0, tree_for_char_literal203 ) # at file 461:31: ( NL )+ match_count_80 = 0 while true alt_80 = 2 look_80_0 = @input.peek( 1 ) if ( look_80_0 == NL ) alt_80 = 1 end case alt_80 when 1 # at line 461:31: NL __NL204__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1270 ) tree_for_NL204 = @adaptor.create_with_payload( __NL204__ ) @adaptor.add_child( root_0, tree_for_NL204 ) else match_count_80 > 0 and break eee = EarlyExit(80) raise eee end match_count_80 += 1 end # --> action self.goto_parent() # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 463:4: 'sometime' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ string_literal205 = match( T__50, TOKENS_FOLLOWING_T__50_IN_goal_body_1280 ) tree_for_string_literal205 = @adaptor.create_with_payload( string_literal205 ) @adaptor.add_child( root_0, tree_for_string_literal205 ) # at line 463:15: ( NL )* while true # decision 81 alt_81 = 2 look_81_0 = @input.peek( 1 ) if ( look_81_0 == NL ) alt_81 = 1 end case alt_81 when 1 # at line 463:15: NL __NL206__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1282 ) tree_for_NL206 = @adaptor.create_with_payload( __NL206__ ) @adaptor.add_child( root_0, tree_for_NL206 ) else break # out of loop for decision 81 end end # loop for decision 81 # --> action @now['sometime'] = self.create_constraint('sometime', 'or') if not @now.has_key?('sometime') @now = @now['sometime'] id = self.next_id.to_s @now[id] = self.create_constraint(id, 'and') @now = @now[id] # <-- action char_literal207 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1291 ) tree_for_char_literal207 = @adaptor.create_with_payload( char_literal207 ) @adaptor.add_child( root_0, tree_for_char_literal207 ) # at line 472:7: ( NL )* while true # decision 82 alt_82 = 2 look_82_0 = @input.peek( 1 ) if ( look_82_0 == NL ) alt_82 = 1 end case alt_82 when 1 # at line 472:7: NL __NL208__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1293 ) tree_for_NL208 = @adaptor.create_with_payload( __NL208__ ) @adaptor.add_child( root_0, tree_for_NL208 ) else break # out of loop for decision 82 end end # loop for decision 82 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1296 ) constraint_body209 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body209.tree ) char_literal210 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1298 ) tree_for_char_literal210 = @adaptor.create_with_payload( char_literal210 ) @adaptor.add_child( root_0, tree_for_char_literal210 ) # at file 472:31: ( NL )+ match_count_83 = 0 while true alt_83 = 2 look_83_0 = @input.peek( 1 ) if ( look_83_0 == NL ) alt_83 = 1 end case alt_83 when 1 # at line 472:31: NL __NL211__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1300 ) tree_for_NL211 = @adaptor.create_with_payload( __NL211__ ) @adaptor.add_child( root_0, tree_for_NL211 ) else match_count_83 > 0 and break eee = EarlyExit(83) raise eee end match_count_83 += 1 end # --> action self.goto_parent() # <-- action # --> action self.goto_parent() # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 475:4: 'within' NUMBER ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ string_literal212 = match( T__51, TOKENS_FOLLOWING_T__51_IN_goal_body_1314 ) tree_for_string_literal212 = @adaptor.create_with_payload( string_literal212 ) @adaptor.add_child( root_0, tree_for_string_literal212 ) __NUMBER213__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_goal_body_1316 ) tree_for_NUMBER213 = @adaptor.create_with_payload( __NUMBER213__ ) @adaptor.add_child( root_0, tree_for_NUMBER213 ) # at line 475:20: ( NL )* while true # decision 84 alt_84 = 2 look_84_0 = @input.peek( 1 ) if ( look_84_0 == NL ) alt_84 = 1 end case alt_84 when 1 # at line 475:20: NL __NL214__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1318 ) tree_for_NL214 = @adaptor.create_with_payload( __NL214__ ) @adaptor.add_child( root_0, tree_for_NL214 ) else break # out of loop for decision 84 end end # loop for decision 84 # --> action id = self.next_id.to_s @now[id] = self.create_constraint(id, 'within') @now = @now[id] @now['deadline'] = __NUMBER213__.text.to_s.to_i # <-- action char_literal215 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1327 ) tree_for_char_literal215 = @adaptor.create_with_payload( char_literal215 ) @adaptor.add_child( root_0, tree_for_char_literal215 ) # at line 482:7: ( NL )* while true # decision 85 alt_85 = 2 look_85_0 = @input.peek( 1 ) if ( look_85_0 == NL ) alt_85 = 1 end case alt_85 when 1 # at line 482:7: NL __NL216__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1329 ) tree_for_NL216 = @adaptor.create_with_payload( __NL216__ ) @adaptor.add_child( root_0, tree_for_NL216 ) else break # out of loop for decision 85 end end # loop for decision 85 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1332 ) constraint_body217 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body217.tree ) char_literal218 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1334 ) tree_for_char_literal218 = @adaptor.create_with_payload( char_literal218 ) @adaptor.add_child( root_0, tree_for_char_literal218 ) # at file 482:31: ( NL )+ match_count_86 = 0 while true alt_86 = 2 look_86_0 = @input.peek( 1 ) if ( look_86_0 == NL ) alt_86 = 1 end case alt_86 when 1 # at line 482:31: NL __NL219__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1336 ) tree_for_NL219 = @adaptor.create_with_payload( __NL219__ ) @adaptor.add_child( root_0, tree_for_NL219 ) else match_count_86 > 0 and break eee = EarlyExit(86) raise eee end match_count_86 += 1 end # --> action self.goto_parent() # <-- action when 5 root_0 = @adaptor.create_flat_list # at line 484:4: 'after' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* ( 'then' | 'within' NUMBER ) ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ string_literal220 = match( T__52, TOKENS_FOLLOWING_T__52_IN_goal_body_1346 ) tree_for_string_literal220 = @adaptor.create_with_payload( string_literal220 ) @adaptor.add_child( root_0, tree_for_string_literal220 ) # at line 484:12: ( NL )* while true # decision 87 alt_87 = 2 look_87_0 = @input.peek( 1 ) if ( look_87_0 == NL ) alt_87 = 1 end case alt_87 when 1 # at line 484:12: NL __NL221__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1348 ) tree_for_NL221 = @adaptor.create_with_payload( __NL221__ ) @adaptor.add_child( root_0, tree_for_NL221 ) else break # out of loop for decision 87 end end # loop for decision 87 # --> action @now['sometime-after'] = self.create_constraint('sometime-after', 'or') if not @now.has_key?('sometime-after') @now = @now['sometime-after'] id = self.next_id.to_s @now[id] = self.create_constraint(id, 'sometime-after') @now = @now[id] @now['after'] = self.create_constraint('after') @now['deadline'] = -1 @now = @now['after'] # <-- action char_literal222 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1357 ) tree_for_char_literal222 = @adaptor.create_with_payload( char_literal222 ) @adaptor.add_child( root_0, tree_for_char_literal222 ) # at line 497:7: ( NL )* while true # decision 88 alt_88 = 2 look_88_0 = @input.peek( 1 ) if ( look_88_0 == NL ) alt_88 = 1 end case alt_88 when 1 # at line 497:7: NL __NL223__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1359 ) tree_for_NL223 = @adaptor.create_with_payload( __NL223__ ) @adaptor.add_child( root_0, tree_for_NL223 ) else break # out of loop for decision 88 end end # loop for decision 88 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1362 ) constraint_body224 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body224.tree ) char_literal225 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1364 ) tree_for_char_literal225 = @adaptor.create_with_payload( char_literal225 ) @adaptor.add_child( root_0, tree_for_char_literal225 ) # at line 497:31: ( NL )* while true # decision 89 alt_89 = 2 look_89_0 = @input.peek( 1 ) if ( look_89_0 == NL ) alt_89 = 1 end case alt_89 when 1 # at line 497:31: NL __NL226__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1366 ) tree_for_NL226 = @adaptor.create_with_payload( __NL226__ ) @adaptor.add_child( root_0, tree_for_NL226 ) else break # out of loop for decision 89 end end # loop for decision 89 # --> action self.goto_parent() # <-- action # at line 499:3: ( 'then' | 'within' NUMBER ) alt_90 = 2 look_90_0 = @input.peek( 1 ) if ( look_90_0 == T__33 ) alt_90 = 1 elsif ( look_90_0 == T__51 ) alt_90 = 2 else raise NoViableAlternative( "", 90, 0 ) end case alt_90 when 1 # at line 499:5: 'then' string_literal227 = match( T__33, TOKENS_FOLLOWING_T__33_IN_goal_body_1377 ) tree_for_string_literal227 = @adaptor.create_with_payload( string_literal227 ) @adaptor.add_child( root_0, tree_for_string_literal227 ) when 2 # at line 500:6: 'within' NUMBER string_literal228 = match( T__51, TOKENS_FOLLOWING_T__51_IN_goal_body_1384 ) tree_for_string_literal228 = @adaptor.create_with_payload( string_literal228 ) @adaptor.add_child( root_0, tree_for_string_literal228 ) __NUMBER229__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_goal_body_1386 ) tree_for_NUMBER229 = @adaptor.create_with_payload( __NUMBER229__ ) @adaptor.add_child( root_0, tree_for_NUMBER229 ) # --> action @now['deadline'] = __NUMBER229__.text.to_s.to_i # <-- action end # at line 502:5: ( NL )* while true # decision 91 alt_91 = 2 look_91_0 = @input.peek( 1 ) if ( look_91_0 == NL ) alt_91 = 1 end case alt_91 when 1 # at line 502:5: NL __NL230__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1398 ) tree_for_NL230 = @adaptor.create_with_payload( __NL230__ ) @adaptor.add_child( root_0, tree_for_NL230 ) else break # out of loop for decision 91 end end # loop for decision 91 # --> action @now['then'] = self.create_constraint('then') @now = @now['then'] # <-- action char_literal231 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1407 ) tree_for_char_literal231 = @adaptor.create_with_payload( char_literal231 ) @adaptor.add_child( root_0, tree_for_char_literal231 ) # at line 507:7: ( NL )* while true # decision 92 alt_92 = 2 look_92_0 = @input.peek( 1 ) if ( look_92_0 == NL ) alt_92 = 1 end case alt_92 when 1 # at line 507:7: NL __NL232__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1409 ) tree_for_NL232 = @adaptor.create_with_payload( __NL232__ ) @adaptor.add_child( root_0, tree_for_NL232 ) else break # out of loop for decision 92 end end # loop for decision 92 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1412 ) constraint_body233 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body233.tree ) char_literal234 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1414 ) tree_for_char_literal234 = @adaptor.create_with_payload( char_literal234 ) @adaptor.add_child( root_0, tree_for_char_literal234 ) # at file 507:31: ( NL )+ match_count_93 = 0 while true alt_93 = 2 look_93_0 = @input.peek( 1 ) if ( look_93_0 == NL ) alt_93 = 1 end case alt_93 when 1 # at line 507:31: NL __NL235__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1416 ) tree_for_NL235 = @adaptor.create_with_payload( __NL235__ ) @adaptor.add_child( root_0, tree_for_NL235 ) else match_count_93 > 0 and break eee = EarlyExit(93) raise eee end match_count_93 += 1 end # --> action self.goto_parent() # <-- action # --> action self.goto_parent() # <-- action # --> action self.goto_parent() # <-- action when 6 root_0 = @adaptor.create_flat_list # at line 511:4: 'before' ( NL )* '{' ( NL )* constraint_body '}' ( NL )* 'then' ( NL )* '{' ( NL )* constraint_body '}' ( NL )+ string_literal236 = match( T__53, TOKENS_FOLLOWING_T__53_IN_goal_body_1434 ) tree_for_string_literal236 = @adaptor.create_with_payload( string_literal236 ) @adaptor.add_child( root_0, tree_for_string_literal236 ) # at line 511:13: ( NL )* while true # decision 94 alt_94 = 2 look_94_0 = @input.peek( 1 ) if ( look_94_0 == NL ) alt_94 = 1 end case alt_94 when 1 # at line 511:13: NL __NL237__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1436 ) tree_for_NL237 = @adaptor.create_with_payload( __NL237__ ) @adaptor.add_child( root_0, tree_for_NL237 ) else break # out of loop for decision 94 end end # loop for decision 94 # --> action id = self.next_id.to_s @now[id] = self.create_constraint(id, 'sometime-before') @now = @now[id] @now['before'] = self.create_constraint('before') @now = @now['before'] # <-- action char_literal238 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1445 ) tree_for_char_literal238 = @adaptor.create_with_payload( char_literal238 ) @adaptor.add_child( root_0, tree_for_char_literal238 ) # at line 519:7: ( NL )* while true # decision 95 alt_95 = 2 look_95_0 = @input.peek( 1 ) if ( look_95_0 == NL ) alt_95 = 1 end case alt_95 when 1 # at line 519:7: NL __NL239__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1447 ) tree_for_NL239 = @adaptor.create_with_payload( __NL239__ ) @adaptor.add_child( root_0, tree_for_NL239 ) else break # out of loop for decision 95 end end # loop for decision 95 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1450 ) constraint_body240 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body240.tree ) char_literal241 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1452 ) tree_for_char_literal241 = @adaptor.create_with_payload( char_literal241 ) @adaptor.add_child( root_0, tree_for_char_literal241 ) # at line 519:31: ( NL )* while true # decision 96 alt_96 = 2 look_96_0 = @input.peek( 1 ) if ( look_96_0 == NL ) alt_96 = 1 end case alt_96 when 1 # at line 519:31: NL __NL242__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1454 ) tree_for_NL242 = @adaptor.create_with_payload( __NL242__ ) @adaptor.add_child( root_0, tree_for_NL242 ) else break # out of loop for decision 96 end end # loop for decision 96 # --> action self.goto_parent() # <-- action string_literal243 = match( T__33, TOKENS_FOLLOWING_T__33_IN_goal_body_1463 ) tree_for_string_literal243 = @adaptor.create_with_payload( string_literal243 ) @adaptor.add_child( root_0, tree_for_string_literal243 ) # at line 521:10: ( NL )* while true # decision 97 alt_97 = 2 look_97_0 = @input.peek( 1 ) if ( look_97_0 == NL ) alt_97 = 1 end case alt_97 when 1 # at line 521:10: NL __NL244__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1465 ) tree_for_NL244 = @adaptor.create_with_payload( __NL244__ ) @adaptor.add_child( root_0, tree_for_NL244 ) else break # out of loop for decision 97 end end # loop for decision 97 # --> action @now['then'] = self.create_constraint('then') @now = @now['then'] # <-- action char_literal245 = match( T__20, TOKENS_FOLLOWING_T__20_IN_goal_body_1474 ) tree_for_char_literal245 = @adaptor.create_with_payload( char_literal245 ) @adaptor.add_child( root_0, tree_for_char_literal245 ) # at line 526:7: ( NL )* while true # decision 98 alt_98 = 2 look_98_0 = @input.peek( 1 ) if ( look_98_0 == NL ) alt_98 = 1 end case alt_98 when 1 # at line 526:7: NL __NL246__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1476 ) tree_for_NL246 = @adaptor.create_with_payload( __NL246__ ) @adaptor.add_child( root_0, tree_for_NL246 ) else break # out of loop for decision 98 end end # loop for decision 98 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_goal_body_1479 ) constraint_body247 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body247.tree ) char_literal248 = match( T__21, TOKENS_FOLLOWING_T__21_IN_goal_body_1481 ) tree_for_char_literal248 = @adaptor.create_with_payload( char_literal248 ) @adaptor.add_child( root_0, tree_for_char_literal248 ) # at file 526:31: ( NL )+ match_count_99 = 0 while true alt_99 = 2 look_99_0 = @input.peek( 1 ) if ( look_99_0 == NL ) alt_99 = 1 end case alt_99 when 1 # at line 526:31: NL __NL249__ = match( NL, TOKENS_FOLLOWING_NL_IN_goal_body_1483 ) tree_for_NL249 = @adaptor.create_with_payload( __NL249__ ) @adaptor.add_child( root_0, tree_for_NL249 ) else match_count_99 > 0 and break eee = EarlyExit(99) raise eee end match_count_99 += 1 end # --> action self.goto_parent() # <-- action # --> action self.goto_parent() # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 31 ) end return return_value end NestedConstraintReturnValue = define_return_scope # # parser rule nested_constraint # # (in SfpLang.g) # 531:1: nested_constraint : '{' ( NL )* constraint_body '}' ; # def nested_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 32 ) return_value = NestedConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal250 = nil __NL251__ = nil char_literal253 = nil constraint_body252 = nil tree_for_char_literal250 = nil tree_for_NL251 = nil tree_for_char_literal253 = nil begin root_0 = @adaptor.create_flat_list # at line 532:4: '{' ( NL )* constraint_body '}' char_literal250 = match( T__20, TOKENS_FOLLOWING_T__20_IN_nested_constraint_1503 ) tree_for_char_literal250 = @adaptor.create_with_payload( char_literal250 ) @adaptor.add_child( root_0, tree_for_char_literal250 ) # at line 532:8: ( NL )* while true # decision 101 alt_101 = 2 look_101_0 = @input.peek( 1 ) if ( look_101_0 == NL ) alt_101 = 1 end case alt_101 when 1 # at line 532:8: NL __NL251__ = match( NL, TOKENS_FOLLOWING_NL_IN_nested_constraint_1505 ) tree_for_NL251 = @adaptor.create_with_payload( __NL251__ ) @adaptor.add_child( root_0, tree_for_NL251 ) else break # out of loop for decision 101 end end # loop for decision 101 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_nested_constraint_1508 ) constraint_body252 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body252.tree ) char_literal253 = match( T__21, TOKENS_FOLLOWING_T__21_IN_nested_constraint_1510 ) tree_for_char_literal253 = @adaptor.create_with_payload( char_literal253 ) @adaptor.add_child( root_0, tree_for_char_literal253 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 32 ) end return return_value end ConstraintReturnValue = define_return_scope # # parser rule constraint # # (in SfpLang.g) # 535:1: constraint : 'constraint' ID '{' ( NL )* constraint_body '}' ; # def constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 33 ) return_value = ConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal254 = nil __ID255__ = nil char_literal256 = nil __NL257__ = nil char_literal259 = nil constraint_body258 = nil tree_for_string_literal254 = nil tree_for_ID255 = nil tree_for_char_literal256 = nil tree_for_NL257 = nil tree_for_char_literal259 = nil begin root_0 = @adaptor.create_flat_list # at line 536:4: 'constraint' ID '{' ( NL )* constraint_body '}' string_literal254 = match( T__47, TOKENS_FOLLOWING_T__47_IN_constraint_1521 ) tree_for_string_literal254 = @adaptor.create_with_payload( string_literal254 ) @adaptor.add_child( root_0, tree_for_string_literal254 ) __ID255__ = match( ID, TOKENS_FOLLOWING_ID_IN_constraint_1523 ) tree_for_ID255 = @adaptor.create_with_payload( __ID255__ ) @adaptor.add_child( root_0, tree_for_ID255 ) # --> action @now[__ID255__.text] = self.create_constraint(__ID255__.text, 'and') @now = @now[__ID255__.text] # <-- action char_literal256 = match( T__20, TOKENS_FOLLOWING_T__20_IN_constraint_1531 ) tree_for_char_literal256 = @adaptor.create_with_payload( char_literal256 ) @adaptor.add_child( root_0, tree_for_char_literal256 ) # at line 541:7: ( NL )* while true # decision 102 alt_102 = 2 look_102_0 = @input.peek( 1 ) if ( look_102_0 == NL ) alt_102 = 1 end case alt_102 when 1 # at line 541:7: NL __NL257__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_1533 ) tree_for_NL257 = @adaptor.create_with_payload( __NL257__ ) @adaptor.add_child( root_0, tree_for_NL257 ) else break # out of loop for decision 102 end end # loop for decision 102 @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_constraint_1536 ) constraint_body258 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body258.tree ) char_literal259 = match( T__21, TOKENS_FOLLOWING_T__21_IN_constraint_1538 ) tree_for_char_literal259 = @adaptor.create_with_payload( char_literal259 ) @adaptor.add_child( root_0, tree_for_char_literal259 ) # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 33 ) end return return_value end ConstraintBodyReturnValue = define_return_scope # # parser rule constraint_body # # (in SfpLang.g) # 545:1: constraint_body : ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ )* ; # def constraint_body # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 34 ) return_value = ConstraintBodyReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL264__ = nil constraint_statement260 = nil constraint_namespace261 = nil constraint_iterator262 = nil constraint_class_quantification263 = nil tree_for_NL264 = nil begin root_0 = @adaptor.create_flat_list # at line 546:4: ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ )* # at line 546:4: ( ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ )* while true # decision 105 alt_105 = 2 look_105_0 = @input.peek( 1 ) if ( look_105_0 == ID || look_105_0 == T__32 || look_105_0 == T__54 || look_105_0.between?( T__56, T__58 ) || look_105_0 == T__61 || look_105_0 == T__67 ) alt_105 = 1 end case alt_105 when 1 # at line 547:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) ( NL )+ # at line 547:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) alt_103 = 4 alt_103 = @dfa103.predict( @input ) case alt_103 when 1 # at line 547:6: constraint_statement @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_constraint_body_1560 ) constraint_statement260 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement260.tree ) # --> action @now[( constraint_statement260.nil? ? nil : constraint_statement260.key )] = ( constraint_statement260.nil? ? nil : constraint_statement260.val ) # <-- action when 2 # at line 551:6: constraint_namespace @state.following.push( TOKENS_FOLLOWING_constraint_namespace_IN_constraint_body_1573 ) constraint_namespace261 = constraint_namespace @state.following.pop @adaptor.add_child( root_0, constraint_namespace261.tree ) when 3 # at line 552:6: constraint_iterator @state.following.push( TOKENS_FOLLOWING_constraint_iterator_IN_constraint_body_1580 ) constraint_iterator262 = constraint_iterator @state.following.pop @adaptor.add_child( root_0, constraint_iterator262.tree ) when 4 # at line 553:6: constraint_class_quantification @state.following.push( TOKENS_FOLLOWING_constraint_class_quantification_IN_constraint_body_1587 ) constraint_class_quantification263 = constraint_class_quantification @state.following.pop @adaptor.add_child( root_0, constraint_class_quantification263.tree ) end # at file 555:3: ( NL )+ match_count_104 = 0 while true alt_104 = 2 look_104_0 = @input.peek( 1 ) if ( look_104_0 == NL ) alt_104 = 1 end case alt_104 when 1 # at line 555:3: NL __NL264__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_body_1596 ) tree_for_NL264 = @adaptor.create_with_payload( __NL264__ ) @adaptor.add_child( root_0, tree_for_NL264 ) else match_count_104 > 0 and break eee = EarlyExit(104) raise eee end match_count_104 += 1 end else break # out of loop for decision 105 end end # loop for decision 105 # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 34 ) end return return_value end ConstraintNamespaceReturnValue = define_return_scope # # parser rule constraint_namespace # # (in SfpLang.g) # 558:1: constraint_namespace : path ( NL )* '{' ( NL )* ( constraint_statement ( NL )+ )* '}' ; # def constraint_namespace # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 35 ) return_value = ConstraintNamespaceReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL266__ = nil char_literal267 = nil __NL268__ = nil __NL270__ = nil char_literal271 = nil path265 = nil constraint_statement269 = nil tree_for_NL266 = nil tree_for_char_literal267 = nil tree_for_NL268 = nil tree_for_NL270 = nil tree_for_char_literal271 = nil begin root_0 = @adaptor.create_flat_list # at line 559:4: path ( NL )* '{' ( NL )* ( constraint_statement ( NL )+ )* '}' @state.following.push( TOKENS_FOLLOWING_path_IN_constraint_namespace_1610 ) path265 = path @state.following.pop @adaptor.add_child( root_0, path265.tree ) # at line 559:9: ( NL )* while true # decision 106 alt_106 = 2 look_106_0 = @input.peek( 1 ) if ( look_106_0 == NL ) alt_106 = 1 end case alt_106 when 1 # at line 559:9: NL __NL266__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_namespace_1612 ) tree_for_NL266 = @adaptor.create_with_payload( __NL266__ ) @adaptor.add_child( root_0, tree_for_NL266 ) else break # out of loop for decision 106 end end # loop for decision 106 char_literal267 = match( T__20, TOKENS_FOLLOWING_T__20_IN_constraint_namespace_1615 ) tree_for_char_literal267 = @adaptor.create_with_payload( char_literal267 ) @adaptor.add_child( root_0, tree_for_char_literal267 ) # at line 559:17: ( NL )* while true # decision 107 alt_107 = 2 look_107_0 = @input.peek( 1 ) if ( look_107_0 == NL ) alt_107 = 1 end case alt_107 when 1 # at line 559:17: NL __NL268__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_namespace_1617 ) tree_for_NL268 = @adaptor.create_with_payload( __NL268__ ) @adaptor.add_child( root_0, tree_for_NL268 ) else break # out of loop for decision 107 end end # loop for decision 107 # at line 559:21: ( constraint_statement ( NL )+ )* while true # decision 109 alt_109 = 2 look_109_0 = @input.peek( 1 ) if ( look_109_0 == ID || look_109_0 == T__32 || look_109_0 == T__61 || look_109_0 == T__67 ) alt_109 = 1 end case alt_109 when 1 # at line 559:22: constraint_statement ( NL )+ @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_constraint_namespace_1621 ) constraint_statement269 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement269.tree ) # --> action key = self.to_ref(( path265 && @input.to_s( path265.start, path265.stop ) ) + '.' + ( constraint_statement269.nil? ? nil : constraint_statement269.key )[2,( constraint_statement269.nil? ? nil : constraint_statement269.key ).length]) @now[key] = ( constraint_statement269.nil? ? nil : constraint_statement269.val ) # <-- action # at file 564:3: ( NL )+ match_count_108 = 0 while true alt_108 = 2 look_108_0 = @input.peek( 1 ) if ( look_108_0 == NL ) alt_108 = 1 end case alt_108 when 1 # at line 564:3: NL __NL270__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_namespace_1629 ) tree_for_NL270 = @adaptor.create_with_payload( __NL270__ ) @adaptor.add_child( root_0, tree_for_NL270 ) else match_count_108 > 0 and break eee = EarlyExit(108) raise eee end match_count_108 += 1 end else break # out of loop for decision 109 end end # loop for decision 109 char_literal271 = match( T__21, TOKENS_FOLLOWING_T__21_IN_constraint_namespace_1634 ) tree_for_char_literal271 = @adaptor.create_with_payload( char_literal271 ) @adaptor.add_child( root_0, tree_for_char_literal271 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 35 ) end return return_value end ConstraintIteratorReturnValue = define_return_scope # # parser rule constraint_iterator # # (in SfpLang.g) # 567:1: constraint_iterator : 'foreach' '(' path 'as' ID ')' ( NL )* '{' ( NL )+ ( constraint_statement ( NL )+ )* '}' ; # def constraint_iterator # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 36 ) return_value = ConstraintIteratorReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal272 = nil char_literal273 = nil string_literal275 = nil __ID276__ = nil char_literal277 = nil __NL278__ = nil char_literal279 = nil __NL280__ = nil __NL282__ = nil char_literal283 = nil path274 = nil constraint_statement281 = nil tree_for_string_literal272 = nil tree_for_char_literal273 = nil tree_for_string_literal275 = nil tree_for_ID276 = nil tree_for_char_literal277 = nil tree_for_NL278 = nil tree_for_char_literal279 = nil tree_for_NL280 = nil tree_for_NL282 = nil tree_for_char_literal283 = nil begin root_0 = @adaptor.create_flat_list # at line 568:4: 'foreach' '(' path 'as' ID ')' ( NL )* '{' ( NL )+ ( constraint_statement ( NL )+ )* '}' string_literal272 = match( T__54, TOKENS_FOLLOWING_T__54_IN_constraint_iterator_1645 ) tree_for_string_literal272 = @adaptor.create_with_payload( string_literal272 ) @adaptor.add_child( root_0, tree_for_string_literal272 ) char_literal273 = match( T__41, TOKENS_FOLLOWING_T__41_IN_constraint_iterator_1647 ) tree_for_char_literal273 = @adaptor.create_with_payload( char_literal273 ) @adaptor.add_child( root_0, tree_for_char_literal273 ) @state.following.push( TOKENS_FOLLOWING_path_IN_constraint_iterator_1649 ) path274 = path @state.following.pop @adaptor.add_child( root_0, path274.tree ) string_literal275 = match( T__55, TOKENS_FOLLOWING_T__55_IN_constraint_iterator_1651 ) tree_for_string_literal275 = @adaptor.create_with_payload( string_literal275 ) @adaptor.add_child( root_0, tree_for_string_literal275 ) __ID276__ = match( ID, TOKENS_FOLLOWING_ID_IN_constraint_iterator_1653 ) tree_for_ID276 = @adaptor.create_with_payload( __ID276__ ) @adaptor.add_child( root_0, tree_for_ID276 ) char_literal277 = match( T__42, TOKENS_FOLLOWING_T__42_IN_constraint_iterator_1655 ) tree_for_char_literal277 = @adaptor.create_with_payload( char_literal277 ) @adaptor.add_child( root_0, tree_for_char_literal277 ) # at line 568:35: ( NL )* while true # decision 110 alt_110 = 2 look_110_0 = @input.peek( 1 ) if ( look_110_0 == NL ) alt_110 = 1 end case alt_110 when 1 # at line 568:35: NL __NL278__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_iterator_1657 ) tree_for_NL278 = @adaptor.create_with_payload( __NL278__ ) @adaptor.add_child( root_0, tree_for_NL278 ) else break # out of loop for decision 110 end end # loop for decision 110 char_literal279 = match( T__20, TOKENS_FOLLOWING_T__20_IN_constraint_iterator_1660 ) tree_for_char_literal279 = @adaptor.create_with_payload( char_literal279 ) @adaptor.add_child( root_0, tree_for_char_literal279 ) # at file 568:43: ( NL )+ match_count_111 = 0 while true alt_111 = 2 look_111_0 = @input.peek( 1 ) if ( look_111_0 == NL ) alt_111 = 1 end case alt_111 when 1 # at line 568:43: NL __NL280__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_iterator_1662 ) tree_for_NL280 = @adaptor.create_with_payload( __NL280__ ) @adaptor.add_child( root_0, tree_for_NL280 ) else match_count_111 > 0 and break eee = EarlyExit(111) raise eee end match_count_111 += 1 end # --> action id = self.next_id.to_s @now[id] = self.create_constraint(id, 'iterator') @now[id]['_value'] = '$.' + ( path274 && @input.to_s( path274.start, path274.stop ) ) @now[id]['_variable'] = __ID276__.text @now = @now[id] id = '_template' @now[id] = self.create_constraint(id, 'and') @now = @now[id] # <-- action # at line 580:3: ( constraint_statement ( NL )+ )* while true # decision 113 alt_113 = 2 look_113_0 = @input.peek( 1 ) if ( look_113_0 == ID || look_113_0 == T__32 || look_113_0 == T__61 || look_113_0 == T__67 ) alt_113 = 1 end case alt_113 when 1 # at line 580:4: constraint_statement ( NL )+ @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_constraint_iterator_1672 ) constraint_statement281 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement281.tree ) # --> action @now[( constraint_statement281.nil? ? nil : constraint_statement281.key )] = ( constraint_statement281.nil? ? nil : constraint_statement281.val ) # <-- action # at file 584:3: ( NL )+ match_count_112 = 0 while true alt_112 = 2 look_112_0 = @input.peek( 1 ) if ( look_112_0 == NL ) alt_112 = 1 end case alt_112 when 1 # at line 584:3: NL __NL282__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_iterator_1680 ) tree_for_NL282 = @adaptor.create_with_payload( __NL282__ ) @adaptor.add_child( root_0, tree_for_NL282 ) else match_count_112 > 0 and break eee = EarlyExit(112) raise eee end match_count_112 += 1 end else break # out of loop for decision 113 end end # loop for decision 113 char_literal283 = match( T__21, TOKENS_FOLLOWING_T__21_IN_constraint_iterator_1687 ) tree_for_char_literal283 = @adaptor.create_with_payload( char_literal283 ) @adaptor.add_child( root_0, tree_for_char_literal283 ) # --> action self.goto_parent() self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 36 ) end return return_value end QuantificationKeywordReturnValue = define_return_scope # # parser rule quantification_keyword # # (in SfpLang.g) # 592:1: quantification_keyword : ( 'forall' | 'exist' | 'forsome' ); # def quantification_keyword # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 37 ) return_value = QuantificationKeywordReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set284 = nil tree_for_set284 = nil begin root_0 = @adaptor.create_flat_list # at line set284 = @input.look if @input.peek( 1 ).between?( T__56, T__58 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set284 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 37 ) end return return_value end ConstraintClassQuantificationReturnValue = define_return_scope # # parser rule constraint_class_quantification # # (in SfpLang.g) # 598:1: constraint_class_quantification : quantification_keyword '(' path 'as' ID ')' ( ( binary_comp | '=' ) NUMBER )? ( NL )* '{' ( NL )+ ( constraint_statement ( NL )+ | constraint_different ( NL )+ | constraint_iterator ( NL )+ )* '}' ; # def constraint_class_quantification # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 38 ) return_value = ConstraintClassQuantificationReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal286 = nil string_literal288 = nil __ID289__ = nil char_literal290 = nil char_literal292 = nil __NUMBER293__ = nil __NL294__ = nil char_literal295 = nil __NL296__ = nil __NL298__ = nil __NL300__ = nil __NL302__ = nil char_literal303 = nil quantification_keyword285 = nil path287 = nil binary_comp291 = nil constraint_statement297 = nil constraint_different299 = nil constraint_iterator301 = nil tree_for_char_literal286 = nil tree_for_string_literal288 = nil tree_for_ID289 = nil tree_for_char_literal290 = nil tree_for_char_literal292 = nil tree_for_NUMBER293 = nil tree_for_NL294 = nil tree_for_char_literal295 = nil tree_for_NL296 = nil tree_for_NL298 = nil tree_for_NL300 = nil tree_for_NL302 = nil tree_for_char_literal303 = nil begin root_0 = @adaptor.create_flat_list # at line 599:4: quantification_keyword '(' path 'as' ID ')' ( ( binary_comp | '=' ) NUMBER )? ( NL )* '{' ( NL )+ ( constraint_statement ( NL )+ | constraint_different ( NL )+ | constraint_iterator ( NL )+ )* '}' @state.following.push( TOKENS_FOLLOWING_quantification_keyword_IN_constraint_class_quantification_1723 ) quantification_keyword285 = quantification_keyword @state.following.pop @adaptor.add_child( root_0, quantification_keyword285.tree ) char_literal286 = match( T__41, TOKENS_FOLLOWING_T__41_IN_constraint_class_quantification_1725 ) tree_for_char_literal286 = @adaptor.create_with_payload( char_literal286 ) @adaptor.add_child( root_0, tree_for_char_literal286 ) @state.following.push( TOKENS_FOLLOWING_path_IN_constraint_class_quantification_1727 ) path287 = path @state.following.pop @adaptor.add_child( root_0, path287.tree ) string_literal288 = match( T__55, TOKENS_FOLLOWING_T__55_IN_constraint_class_quantification_1729 ) tree_for_string_literal288 = @adaptor.create_with_payload( string_literal288 ) @adaptor.add_child( root_0, tree_for_string_literal288 ) __ID289__ = match( ID, TOKENS_FOLLOWING_ID_IN_constraint_class_quantification_1731 ) tree_for_ID289 = @adaptor.create_with_payload( __ID289__ ) @adaptor.add_child( root_0, tree_for_ID289 ) char_literal290 = match( T__42, TOKENS_FOLLOWING_T__42_IN_constraint_class_quantification_1733 ) tree_for_char_literal290 = @adaptor.create_with_payload( char_literal290 ) @adaptor.add_child( root_0, tree_for_char_literal290 ) # --> action id = self.next_id.to_s @now[id] = { '_parent' => @now, '_context' => 'constraint', '_type' => ( quantification_keyword285 && @input.to_s( quantification_keyword285.start, quantification_keyword285.stop ) ), '_self' => id, '_class' => ( path287 && @input.to_s( path287.start, path287.stop ) ), '_variable' => __ID289__.text } @now = @now[id] id = '_template' @now[id] = self.create_constraint(id, 'and') @now = @now[id] # <-- action # at line 615:3: ( ( binary_comp | '=' ) NUMBER )? alt_115 = 2 look_115_0 = @input.peek( 1 ) if ( look_115_0 == T__59 || look_115_0.between?( T__81, T__84 ) ) alt_115 = 1 end case alt_115 when 1 # at line 615:5: ( binary_comp | '=' ) NUMBER # at line 615:5: ( binary_comp | '=' ) alt_114 = 2 look_114_0 = @input.peek( 1 ) if ( look_114_0.between?( T__81, T__84 ) ) alt_114 = 1 elsif ( look_114_0 == T__59 ) alt_114 = 2 else raise NoViableAlternative( "", 114, 0 ) end case alt_114 when 1 # at line 615:7: binary_comp @state.following.push( TOKENS_FOLLOWING_binary_comp_IN_constraint_class_quantification_1745 ) binary_comp291 = binary_comp @state.following.pop @adaptor.add_child( root_0, binary_comp291.tree ) # --> action @now['_count_operator'] = ( binary_comp291 && @input.to_s( binary_comp291.start, binary_comp291.stop ) ) # <-- action when 2 # at line 617:6: '=' char_literal292 = match( T__59, TOKENS_FOLLOWING_T__59_IN_constraint_class_quantification_1758 ) tree_for_char_literal292 = @adaptor.create_with_payload( char_literal292 ) @adaptor.add_child( root_0, tree_for_char_literal292 ) # --> action @now['_count_operator'] = '=' # <-- action end __NUMBER293__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_constraint_class_quantification_1774 ) tree_for_NUMBER293 = @adaptor.create_with_payload( __NUMBER293__ ) @adaptor.add_child( root_0, tree_for_NUMBER293 ) # --> action @now['_count_value'] = __NUMBER293__.text.to_i # <-- action end # at line 623:3: ( NL )* while true # decision 116 alt_116 = 2 look_116_0 = @input.peek( 1 ) if ( look_116_0 == NL ) alt_116 = 1 end case alt_116 when 1 # at line 623:3: NL __NL294__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1788 ) tree_for_NL294 = @adaptor.create_with_payload( __NL294__ ) @adaptor.add_child( root_0, tree_for_NL294 ) else break # out of loop for decision 116 end end # loop for decision 116 char_literal295 = match( T__20, TOKENS_FOLLOWING_T__20_IN_constraint_class_quantification_1791 ) tree_for_char_literal295 = @adaptor.create_with_payload( char_literal295 ) @adaptor.add_child( root_0, tree_for_char_literal295 ) # at file 623:11: ( NL )+ match_count_117 = 0 while true alt_117 = 2 look_117_0 = @input.peek( 1 ) if ( look_117_0 == NL ) alt_117 = 1 end case alt_117 when 1 # at line 623:11: NL __NL296__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1793 ) tree_for_NL296 = @adaptor.create_with_payload( __NL296__ ) @adaptor.add_child( root_0, tree_for_NL296 ) else match_count_117 > 0 and break eee = EarlyExit(117) raise eee end match_count_117 += 1 end # at line 624:3: ( constraint_statement ( NL )+ | constraint_different ( NL )+ | constraint_iterator ( NL )+ )* while true # decision 121 alt_121 = 4 case look_121 = @input.peek( 1 ) when ID, T__32, T__61, T__67 then alt_121 = 1 when T__60 then alt_121 = 2 when T__54 then alt_121 = 3 end case alt_121 when 1 # at line 624:5: constraint_statement ( NL )+ @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_constraint_class_quantification_1800 ) constraint_statement297 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement297.tree ) # --> action @now[( constraint_statement297.nil? ? nil : constraint_statement297.key )] = ( constraint_statement297.nil? ? nil : constraint_statement297.val ) # <-- action # at file 626:4: ( NL )+ match_count_118 = 0 while true alt_118 = 2 look_118_0 = @input.peek( 1 ) if ( look_118_0 == NL ) alt_118 = 1 end case alt_118 when 1 # at line 626:4: NL __NL298__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1810 ) tree_for_NL298 = @adaptor.create_with_payload( __NL298__ ) @adaptor.add_child( root_0, tree_for_NL298 ) else match_count_118 > 0 and break eee = EarlyExit(118) raise eee end match_count_118 += 1 end when 2 # at line 627:5: constraint_different ( NL )+ @state.following.push( TOKENS_FOLLOWING_constraint_different_IN_constraint_class_quantification_1817 ) constraint_different299 = constraint_different @state.following.pop @adaptor.add_child( root_0, constraint_different299.tree ) # at file 627:26: ( NL )+ match_count_119 = 0 while true alt_119 = 2 look_119_0 = @input.peek( 1 ) if ( look_119_0 == NL ) alt_119 = 1 end case alt_119 when 1 # at line 627:26: NL __NL300__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1819 ) tree_for_NL300 = @adaptor.create_with_payload( __NL300__ ) @adaptor.add_child( root_0, tree_for_NL300 ) else match_count_119 > 0 and break eee = EarlyExit(119) raise eee end match_count_119 += 1 end when 3 # at line 628:5: constraint_iterator ( NL )+ @state.following.push( TOKENS_FOLLOWING_constraint_iterator_IN_constraint_class_quantification_1826 ) constraint_iterator301 = constraint_iterator @state.following.pop @adaptor.add_child( root_0, constraint_iterator301.tree ) # at file 628:25: ( NL )+ match_count_120 = 0 while true alt_120 = 2 look_120_0 = @input.peek( 1 ) if ( look_120_0 == NL ) alt_120 = 1 end case alt_120 when 1 # at line 628:25: NL __NL302__ = match( NL, TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1828 ) tree_for_NL302 = @adaptor.create_with_payload( __NL302__ ) @adaptor.add_child( root_0, tree_for_NL302 ) else match_count_120 > 0 and break eee = EarlyExit(120) raise eee end match_count_120 += 1 end else break # out of loop for decision 121 end end # loop for decision 121 char_literal303 = match( T__21, TOKENS_FOLLOWING_T__21_IN_constraint_class_quantification_1836 ) tree_for_char_literal303 = @adaptor.create_with_payload( char_literal303 ) @adaptor.add_child( root_0, tree_for_char_literal303 ) # --> action self.goto_parent() # <-- action # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 38 ) end return return_value end ConstraintDifferentReturnValue = define_return_scope # # parser rule constraint_different # # (in SfpLang.g) # 634:1: constraint_different : ':different' '(' path ')' ; # def constraint_different # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 39 ) return_value = ConstraintDifferentReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal304 = nil char_literal305 = nil char_literal307 = nil path306 = nil tree_for_string_literal304 = nil tree_for_char_literal305 = nil tree_for_char_literal307 = nil begin root_0 = @adaptor.create_flat_list # at line 635:4: ':different' '(' path ')' string_literal304 = match( T__60, TOKENS_FOLLOWING_T__60_IN_constraint_different_1855 ) tree_for_string_literal304 = @adaptor.create_with_payload( string_literal304 ) @adaptor.add_child( root_0, tree_for_string_literal304 ) char_literal305 = match( T__41, TOKENS_FOLLOWING_T__41_IN_constraint_different_1857 ) tree_for_char_literal305 = @adaptor.create_with_payload( char_literal305 ) @adaptor.add_child( root_0, tree_for_char_literal305 ) @state.following.push( TOKENS_FOLLOWING_path_IN_constraint_different_1859 ) path306 = path @state.following.pop @adaptor.add_child( root_0, path306.tree ) char_literal307 = match( T__42, TOKENS_FOLLOWING_T__42_IN_constraint_different_1861 ) tree_for_char_literal307 = @adaptor.create_with_payload( char_literal307 ) @adaptor.add_child( root_0, tree_for_char_literal307 ) # --> action id = self.next_id.to_s @now[id] = { '_parent' => @now, '_context' => 'constraint', '_type' => 'different', '_self' => id, '_path' => ( path306 && @input.to_s( path306.start, path306.stop ) ) } # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 39 ) end return return_value end ConstraintStatementReturnValue = define_return_scope :key, :val # # parser rule constraint_statement # # (in SfpLang.g) # 647:1: constraint_statement returns [key, val] : ( reference | 'not' reference | reference equals_op value | reference equals_op NULL | reference not_equals_op value | reference not_equals_op NULL | conditional_constraint | reference ( 'is' )? 'in' set_value | reference ( 'isnot' | 'isnt' | 'not' ) 'in' set_value | reference 'has' value | reference binary_comp comp_value | total_constraint ); # def constraint_statement # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 40 ) return_value = ConstraintStatementReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal309 = nil __NULL316__ = nil __NULL322__ = nil string_literal325 = nil string_literal326 = nil set329 = nil string_literal330 = nil string_literal333 = nil reference308 = nil reference310 = nil reference311 = nil equals_op312 = nil value313 = nil reference314 = nil equals_op315 = nil reference317 = nil not_equals_op318 = nil value319 = nil reference320 = nil not_equals_op321 = nil conditional_constraint323 = nil reference324 = nil set_value327 = nil reference328 = nil set_value331 = nil reference332 = nil value334 = nil reference335 = nil binary_comp336 = nil comp_value337 = nil total_constraint338 = nil tree_for_string_literal309 = nil tree_for_NULL316 = nil tree_for_NULL322 = nil tree_for_string_literal325 = nil tree_for_string_literal326 = nil tree_for_set329 = nil tree_for_string_literal330 = nil tree_for_string_literal333 = nil begin # at line 648:2: ( reference | 'not' reference | reference equals_op value | reference equals_op NULL | reference not_equals_op value | reference not_equals_op NULL | conditional_constraint | reference ( 'is' )? 'in' set_value | reference ( 'isnot' | 'isnt' | 'not' ) 'in' set_value | reference 'has' value | reference binary_comp comp_value | total_constraint ) alt_123 = 12 alt_123 = @dfa123.predict( @input ) case alt_123 when 1 root_0 = @adaptor.create_flat_list # at line 648:4: reference @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1880 ) reference308 = reference @state.following.pop @adaptor.add_child( root_0, reference308.tree ) # --> action return_value.key = ( reference308.nil? ? nil : reference308.val ) return_value.val = { '_context' => 'constraint', '_type' => 'equals', '_value' => true } # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 653:4: 'not' reference string_literal309 = match( T__61, TOKENS_FOLLOWING_T__61_IN_constraint_statement_1889 ) tree_for_string_literal309 = @adaptor.create_with_payload( string_literal309 ) @adaptor.add_child( root_0, tree_for_string_literal309 ) @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1891 ) reference310 = reference @state.following.pop @adaptor.add_child( root_0, reference310.tree ) # --> action return_value.key = ( reference310.nil? ? nil : reference310.val ) return_value.val = { '_context' => 'constraint', '_type' => 'equals', '_value' => false } # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 658:4: reference equals_op value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1900 ) reference311 = reference @state.following.pop @adaptor.add_child( root_0, reference311.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_constraint_statement_1902 ) equals_op312 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op312.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_constraint_statement_1904 ) value313 = value @state.following.pop @adaptor.add_child( root_0, value313.tree ) # --> action return_value.key = ( reference311.nil? ? nil : reference311.val ) return_value.val = { '_context' => 'constraint', '_type' => 'equals', '_value' => ( value313.nil? ? nil : value313.val ) } # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 663:4: reference equals_op NULL @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1913 ) reference314 = reference @state.following.pop @adaptor.add_child( root_0, reference314.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_constraint_statement_1915 ) equals_op315 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op315.tree ) __NULL316__ = match( NULL, TOKENS_FOLLOWING_NULL_IN_constraint_statement_1917 ) tree_for_NULL316 = @adaptor.create_with_payload( __NULL316__ ) @adaptor.add_child( root_0, tree_for_NULL316 ) # --> action return_value.key = ( reference314.nil? ? nil : reference314.val ) return_value.val = { '_context' => 'constraint', '_type' => 'equals', '_value' => self.null_value } # <-- action when 5 root_0 = @adaptor.create_flat_list # at line 668:4: reference not_equals_op value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1926 ) reference317 = reference @state.following.pop @adaptor.add_child( root_0, reference317.tree ) @state.following.push( TOKENS_FOLLOWING_not_equals_op_IN_constraint_statement_1928 ) not_equals_op318 = not_equals_op @state.following.pop @adaptor.add_child( root_0, not_equals_op318.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_constraint_statement_1930 ) value319 = value @state.following.pop @adaptor.add_child( root_0, value319.tree ) # --> action return_value.key = ( reference317.nil? ? nil : reference317.val ) return_value.val = { '_context' => 'constraint', '_type' => 'not-equals', '_value' => ( value319.nil? ? nil : value319.val ) } # <-- action when 6 root_0 = @adaptor.create_flat_list # at line 673:4: reference not_equals_op NULL @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1939 ) reference320 = reference @state.following.pop @adaptor.add_child( root_0, reference320.tree ) @state.following.push( TOKENS_FOLLOWING_not_equals_op_IN_constraint_statement_1941 ) not_equals_op321 = not_equals_op @state.following.pop @adaptor.add_child( root_0, not_equals_op321.tree ) __NULL322__ = match( NULL, TOKENS_FOLLOWING_NULL_IN_constraint_statement_1943 ) tree_for_NULL322 = @adaptor.create_with_payload( __NULL322__ ) @adaptor.add_child( root_0, tree_for_NULL322 ) # --> action return_value.key = ( reference320.nil? ? nil : reference320.val ) return_value.val = { '_context' => 'constraint', '_type' => 'not-equals', '_value' => self.null_value } # <-- action when 7 root_0 = @adaptor.create_flat_list # at line 678:4: conditional_constraint @state.following.push( TOKENS_FOLLOWING_conditional_constraint_IN_constraint_statement_1952 ) conditional_constraint323 = conditional_constraint @state.following.pop @adaptor.add_child( root_0, conditional_constraint323.tree ) # --> action return_value.key = ( conditional_constraint323.nil? ? nil : conditional_constraint323.key ) return_value.val = ( conditional_constraint323.nil? ? nil : conditional_constraint323.val ) # <-- action when 8 root_0 = @adaptor.create_flat_list # at line 683:4: reference ( 'is' )? 'in' set_value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1961 ) reference324 = reference @state.following.pop @adaptor.add_child( root_0, reference324.tree ) # at line 683:14: ( 'is' )? alt_122 = 2 look_122_0 = @input.peek( 1 ) if ( look_122_0 == T__62 ) alt_122 = 1 end case alt_122 when 1 # at line 683:14: 'is' string_literal325 = match( T__62, TOKENS_FOLLOWING_T__62_IN_constraint_statement_1963 ) tree_for_string_literal325 = @adaptor.create_with_payload( string_literal325 ) @adaptor.add_child( root_0, tree_for_string_literal325 ) end string_literal326 = match( T__63, TOKENS_FOLLOWING_T__63_IN_constraint_statement_1966 ) tree_for_string_literal326 = @adaptor.create_with_payload( string_literal326 ) @adaptor.add_child( root_0, tree_for_string_literal326 ) @state.following.push( TOKENS_FOLLOWING_set_value_IN_constraint_statement_1968 ) set_value327 = set_value @state.following.pop @adaptor.add_child( root_0, set_value327.tree ) # --> action c_or = { '_context' => 'constraint', '_type' => 'or', '_parent' => @now } ( set_value327.nil? ? nil : set_value327.val ).each { |v| id = self.next_id.to_s item = { '_context' => 'constraint', '_type' => 'and', '_parent' => c_or } item[( reference324.nil? ? nil : reference324.val )] = { '_context' => 'constraint', '_type' => 'equals', '_value' => v } c_or[id] = item } return_value.key = self.next_id.to_s return_value.val = c_or # <-- action when 9 root_0 = @adaptor.create_flat_list # at line 695:4: reference ( 'isnot' | 'isnt' | 'not' ) 'in' set_value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1977 ) reference328 = reference @state.following.pop @adaptor.add_child( root_0, reference328.tree ) set329 = @input.look if @input.peek(1) == T__61 || @input.peek( 1 ).between?( T__64, T__65 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set329 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end string_literal330 = match( T__63, TOKENS_FOLLOWING_T__63_IN_constraint_statement_1987 ) tree_for_string_literal330 = @adaptor.create_with_payload( string_literal330 ) @adaptor.add_child( root_0, tree_for_string_literal330 ) @state.following.push( TOKENS_FOLLOWING_set_value_IN_constraint_statement_1989 ) set_value331 = set_value @state.following.pop @adaptor.add_child( root_0, set_value331.tree ) # --> action c_and = { '_context'=>'constraint', '_type'=>'and', '_parent'=>@now } ( set_value331.nil? ? nil : set_value331.val ).each { |v| id = self.next_id.to_s item = { '_context'=>'constraint', '_type'=>'and'} item[( reference328.nil? ? nil : reference328.val )] = { '_context'=>'constraint', '_type'=>'not-equals', '_value'=>v } c_and[id] = item } return_value.key = self.next_id.to_s return_value.val = c_and #return_value.key = ( reference328.nil? ? nil : reference328.val ) #return_value.val = { '_context' => 'constraint', '_type' => 'not-in', '_value' => ( set_value331.nil? ? nil : set_value331.val ) } # <-- action when 10 root_0 = @adaptor.create_flat_list # at line 710:4: reference 'has' value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_1998 ) reference332 = reference @state.following.pop @adaptor.add_child( root_0, reference332.tree ) string_literal333 = match( T__66, TOKENS_FOLLOWING_T__66_IN_constraint_statement_2000 ) tree_for_string_literal333 = @adaptor.create_with_payload( string_literal333 ) @adaptor.add_child( root_0, tree_for_string_literal333 ) @state.following.push( TOKENS_FOLLOWING_value_IN_constraint_statement_2002 ) value334 = value @state.following.pop @adaptor.add_child( root_0, value334.tree ) # --> action c_has = { '_context' => 'constraint', '_type' => 'has', '_parent' => @now, '_owner' => ( reference332.nil? ? nil : reference332.val ), '_value' => ( value334.nil? ? nil : value334.val ) } # <-- action when 11 root_0 = @adaptor.create_flat_list # at line 719:4: reference binary_comp comp_value @state.following.push( TOKENS_FOLLOWING_reference_IN_constraint_statement_2011 ) reference335 = reference @state.following.pop @adaptor.add_child( root_0, reference335.tree ) @state.following.push( TOKENS_FOLLOWING_binary_comp_IN_constraint_statement_2013 ) binary_comp336 = binary_comp @state.following.pop @adaptor.add_child( root_0, binary_comp336.tree ) @state.following.push( TOKENS_FOLLOWING_comp_value_IN_constraint_statement_2015 ) comp_value337 = comp_value @state.following.pop @adaptor.add_child( root_0, comp_value337.tree ) # --> action return_value.key = ( reference335.nil? ? nil : reference335.val ) return_value.val = { '_context' => 'constraint', '_type' => ( binary_comp336 && @input.to_s( binary_comp336.start, binary_comp336.stop ) ), '_value' => ( comp_value337.nil? ? nil : comp_value337.val ) } # <-- action when 12 root_0 = @adaptor.create_flat_list # at line 724:4: total_constraint @state.following.push( TOKENS_FOLLOWING_total_constraint_IN_constraint_statement_2024 ) total_constraint338 = total_constraint @state.following.pop @adaptor.add_child( root_0, total_constraint338.tree ) end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 40 ) end return return_value end TotalConstraintReturnValue = define_return_scope # # parser rule total_constraint # # (in SfpLang.g) # 727:1: total_constraint : 'total(' total_statement ')' binary_comp NUMBER ; # def total_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 41 ) return_value = TotalConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal339 = nil char_literal341 = nil __NUMBER343__ = nil total_statement340 = nil binary_comp342 = nil tree_for_string_literal339 = nil tree_for_char_literal341 = nil tree_for_NUMBER343 = nil begin root_0 = @adaptor.create_flat_list # at line 728:4: 'total(' total_statement ')' binary_comp NUMBER string_literal339 = match( T__67, TOKENS_FOLLOWING_T__67_IN_total_constraint_2035 ) tree_for_string_literal339 = @adaptor.create_with_payload( string_literal339 ) @adaptor.add_child( root_0, tree_for_string_literal339 ) @state.following.push( TOKENS_FOLLOWING_total_statement_IN_total_constraint_2037 ) total_statement340 = total_statement @state.following.pop @adaptor.add_child( root_0, total_statement340.tree ) char_literal341 = match( T__42, TOKENS_FOLLOWING_T__42_IN_total_constraint_2039 ) tree_for_char_literal341 = @adaptor.create_with_payload( char_literal341 ) @adaptor.add_child( root_0, tree_for_char_literal341 ) @state.following.push( TOKENS_FOLLOWING_binary_comp_IN_total_constraint_2041 ) binary_comp342 = binary_comp @state.following.pop @adaptor.add_child( root_0, binary_comp342.tree ) __NUMBER343__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_total_constraint_2043 ) tree_for_NUMBER343 = @adaptor.create_with_payload( __NUMBER343__ ) @adaptor.add_child( root_0, tree_for_NUMBER343 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 41 ) end return return_value end TotalStatementReturnValue = define_return_scope # # parser rule total_statement # # (in SfpLang.g) # 731:1: total_statement : reference equals_op value ; # def total_statement # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 42 ) return_value = TotalStatementReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil reference344 = nil equals_op345 = nil value346 = nil begin root_0 = @adaptor.create_flat_list # at line 732:4: reference equals_op value @state.following.push( TOKENS_FOLLOWING_reference_IN_total_statement_2054 ) reference344 = reference @state.following.pop @adaptor.add_child( root_0, reference344.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_total_statement_2056 ) equals_op345 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op345.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_total_statement_2058 ) value346 = value @state.following.pop @adaptor.add_child( root_0, value346.tree ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 42 ) end return return_value end CompValueReturnValue = define_return_scope :val # # parser rule comp_value # # (in SfpLang.g) # 735:1: comp_value returns [val] : ( NUMBER | reference ); # def comp_value # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 43 ) return_value = CompValueReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NUMBER347__ = nil reference348 = nil tree_for_NUMBER347 = nil begin # at line 736:2: ( NUMBER | reference ) alt_124 = 2 look_124_0 = @input.peek( 1 ) if ( look_124_0 == NUMBER ) alt_124 = 1 elsif ( look_124_0 == ID ) alt_124 = 2 else raise NoViableAlternative( "", 124, 0 ) end case alt_124 when 1 root_0 = @adaptor.create_flat_list # at line 736:4: NUMBER __NUMBER347__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_comp_value_2073 ) tree_for_NUMBER347 = @adaptor.create_with_payload( __NUMBER347__ ) @adaptor.add_child( root_0, tree_for_NUMBER347 ) # --> action return_value.val = __NUMBER347__.text.to_i # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 738:4: reference @state.following.push( TOKENS_FOLLOWING_reference_IN_comp_value_2082 ) reference348 = reference @state.following.pop @adaptor.add_child( root_0, reference348.tree ) # --> action return_value.val = ( reference348.nil? ? nil : reference348.val ) # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 43 ) end return return_value end ConditionalConstraintReturnValue = define_return_scope :key, :val # # parser rule conditional_constraint # # (in SfpLang.g) # 742:1: conditional_constraint returns [key, val] : 'if' conditional_constraint_if_part conditional_constraint_then_part ; # def conditional_constraint # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 44 ) return_value = ConditionalConstraintReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal349 = nil conditional_constraint_if_part350 = nil conditional_constraint_then_part351 = nil tree_for_string_literal349 = nil begin root_0 = @adaptor.create_flat_list # at line 743:4: 'if' conditional_constraint_if_part conditional_constraint_then_part string_literal349 = match( T__32, TOKENS_FOLLOWING_T__32_IN_conditional_constraint_2101 ) tree_for_string_literal349 = @adaptor.create_with_payload( string_literal349 ) @adaptor.add_child( root_0, tree_for_string_literal349 ) # --> action return_value.key = id = self.next_id.to_s @now[id] = self.create_constraint(id, 'imply') @now = @now[id] # <-- action @state.following.push( TOKENS_FOLLOWING_conditional_constraint_if_part_IN_conditional_constraint_2109 ) conditional_constraint_if_part350 = conditional_constraint_if_part @state.following.pop @adaptor.add_child( root_0, conditional_constraint_if_part350.tree ) @state.following.push( TOKENS_FOLLOWING_conditional_constraint_then_part_IN_conditional_constraint_2113 ) conditional_constraint_then_part351 = conditional_constraint_then_part @state.following.pop @adaptor.add_child( root_0, conditional_constraint_then_part351.tree ) # --> action return_value.val = self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 44 ) end return return_value end ConditionalConstraintIfPartReturnValue = define_return_scope # # parser rule conditional_constraint_if_part # # (in SfpLang.g) # 754:1: conditional_constraint_if_part : ( constraint_statement ( NL )* | '{' ( NL )+ constraint_body '}' ( NL )* ); # def conditional_constraint_if_part # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 45 ) return_value = ConditionalConstraintIfPartReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL353__ = nil char_literal354 = nil __NL355__ = nil char_literal357 = nil __NL358__ = nil constraint_statement352 = nil constraint_body356 = nil tree_for_NL353 = nil tree_for_char_literal354 = nil tree_for_NL355 = nil tree_for_char_literal357 = nil tree_for_NL358 = nil begin # at line 755:2: ( constraint_statement ( NL )* | '{' ( NL )+ constraint_body '}' ( NL )* ) alt_128 = 2 look_128_0 = @input.peek( 1 ) if ( look_128_0 == ID || look_128_0 == T__32 || look_128_0 == T__61 || look_128_0 == T__67 ) alt_128 = 1 elsif ( look_128_0 == T__20 ) alt_128 = 2 else raise NoViableAlternative( "", 128, 0 ) end case alt_128 when 1 root_0 = @adaptor.create_flat_list # at line 755:4: constraint_statement ( NL )* @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_conditional_constraint_if_part_2128 ) constraint_statement352 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement352.tree ) # at line 755:25: ( NL )* while true # decision 125 alt_125 = 2 look_125_0 = @input.peek( 1 ) if ( look_125_0 == NL ) alt_125 = 1 end case alt_125 when 1 # at line 755:25: NL __NL353__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2130 ) tree_for_NL353 = @adaptor.create_with_payload( __NL353__ ) @adaptor.add_child( root_0, tree_for_NL353 ) else break # out of loop for decision 125 end end # loop for decision 125 # --> action id = self.next_id @now[id] = self.create_constraint(id, 'and') @now[id]['_subtype'] = 'premise' @now[id][( constraint_statement352.nil? ? nil : constraint_statement352.key )] = ( constraint_statement352.nil? ? nil : constraint_statement352.val ) # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 762:4: '{' ( NL )+ constraint_body '}' ( NL )* char_literal354 = match( T__20, TOKENS_FOLLOWING_T__20_IN_conditional_constraint_if_part_2140 ) tree_for_char_literal354 = @adaptor.create_with_payload( char_literal354 ) @adaptor.add_child( root_0, tree_for_char_literal354 ) # --> action id = self.next_id @now[id] = self.create_constraint(id, 'and') @now[id]['_subtype'] = 'premise' @now = @now[id] # <-- action # at file 769:3: ( NL )+ match_count_126 = 0 while true alt_126 = 2 look_126_0 = @input.peek( 1 ) if ( look_126_0 == NL ) alt_126 = 1 end case alt_126 when 1 # at line 769:3: NL __NL355__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2148 ) tree_for_NL355 = @adaptor.create_with_payload( __NL355__ ) @adaptor.add_child( root_0, tree_for_NL355 ) else match_count_126 > 0 and break eee = EarlyExit(126) raise eee end match_count_126 += 1 end @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_conditional_constraint_if_part_2151 ) constraint_body356 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body356.tree ) char_literal357 = match( T__21, TOKENS_FOLLOWING_T__21_IN_conditional_constraint_if_part_2155 ) tree_for_char_literal357 = @adaptor.create_with_payload( char_literal357 ) @adaptor.add_child( root_0, tree_for_char_literal357 ) # at line 770:7: ( NL )* while true # decision 127 alt_127 = 2 look_127_0 = @input.peek( 1 ) if ( look_127_0 == NL ) alt_127 = 1 end case alt_127 when 1 # at line 770:7: NL __NL358__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2157 ) tree_for_NL358 = @adaptor.create_with_payload( __NL358__ ) @adaptor.add_child( root_0, tree_for_NL358 ) else break # out of loop for decision 127 end end # loop for decision 127 # --> action self.goto_parent() # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 45 ) end return return_value end ConditionalConstraintThenPartReturnValue = define_return_scope # # parser rule conditional_constraint_then_part # # (in SfpLang.g) # 774:1: conditional_constraint_then_part : ( 'then' constraint_statement | 'then' '{' ( NL )+ constraint_body '}' ); # def conditional_constraint_then_part # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 46 ) return_value = ConditionalConstraintThenPartReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal359 = nil string_literal361 = nil char_literal362 = nil __NL363__ = nil char_literal365 = nil constraint_statement360 = nil constraint_body364 = nil tree_for_string_literal359 = nil tree_for_string_literal361 = nil tree_for_char_literal362 = nil tree_for_NL363 = nil tree_for_char_literal365 = nil begin # at line 775:2: ( 'then' constraint_statement | 'then' '{' ( NL )+ constraint_body '}' ) alt_130 = 2 look_130_0 = @input.peek( 1 ) if ( look_130_0 == T__33 ) look_130_1 = @input.peek( 2 ) if ( look_130_1 == ID || look_130_1 == T__32 || look_130_1 == T__61 || look_130_1 == T__67 ) alt_130 = 1 elsif ( look_130_1 == T__20 ) alt_130 = 2 else raise NoViableAlternative( "", 130, 1 ) end else raise NoViableAlternative( "", 130, 0 ) end case alt_130 when 1 root_0 = @adaptor.create_flat_list # at line 775:4: 'then' constraint_statement string_literal359 = match( T__33, TOKENS_FOLLOWING_T__33_IN_conditional_constraint_then_part_2173 ) tree_for_string_literal359 = @adaptor.create_with_payload( string_literal359 ) @adaptor.add_child( root_0, tree_for_string_literal359 ) @state.following.push( TOKENS_FOLLOWING_constraint_statement_IN_conditional_constraint_then_part_2175 ) constraint_statement360 = constraint_statement @state.following.pop @adaptor.add_child( root_0, constraint_statement360.tree ) # --> action id = self.next_id @now[id] = self.create_constraint(id, 'and') @now[id]['_subtype'] = 'conclusion' @now[id][( constraint_statement360.nil? ? nil : constraint_statement360.key )] = ( constraint_statement360.nil? ? nil : constraint_statement360.val ) # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 782:4: 'then' '{' ( NL )+ constraint_body '}' string_literal361 = match( T__33, TOKENS_FOLLOWING_T__33_IN_conditional_constraint_then_part_2184 ) tree_for_string_literal361 = @adaptor.create_with_payload( string_literal361 ) @adaptor.add_child( root_0, tree_for_string_literal361 ) # --> action id = self.next_id @now[id] = self.create_constraint(id, 'and') @now[id]['_subtype'] = 'conclusion' @now = @now[id] # <-- action char_literal362 = match( T__20, TOKENS_FOLLOWING_T__20_IN_conditional_constraint_then_part_2192 ) tree_for_char_literal362 = @adaptor.create_with_payload( char_literal362 ) @adaptor.add_child( root_0, tree_for_char_literal362 ) # at file 789:7: ( NL )+ match_count_129 = 0 while true alt_129 = 2 look_129_0 = @input.peek( 1 ) if ( look_129_0 == NL ) alt_129 = 1 end case alt_129 when 1 # at line 789:7: NL __NL363__ = match( NL, TOKENS_FOLLOWING_NL_IN_conditional_constraint_then_part_2194 ) tree_for_NL363 = @adaptor.create_with_payload( __NL363__ ) @adaptor.add_child( root_0, tree_for_NL363 ) else match_count_129 > 0 and break eee = EarlyExit(129) raise eee end match_count_129 += 1 end @state.following.push( TOKENS_FOLLOWING_constraint_body_IN_conditional_constraint_then_part_2197 ) constraint_body364 = constraint_body @state.following.pop @adaptor.add_child( root_0, constraint_body364.tree ) char_literal365 = match( T__21, TOKENS_FOLLOWING_T__21_IN_conditional_constraint_then_part_2199 ) tree_for_char_literal365 = @adaptor.create_with_payload( char_literal365 ) @adaptor.add_child( root_0, tree_for_char_literal365 ) # --> action self.goto_parent() # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 46 ) end return return_value end EffectBodyReturnValue = define_return_scope # # parser rule effect_body # # (in SfpLang.g) # 793:1: effect_body : ( ( mutation | mutation_iterator ) ( NL )+ )* ; # def effect_body # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 47 ) return_value = EffectBodyReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NL368__ = nil mutation366 = nil mutation_iterator367 = nil tree_for_NL368 = nil begin root_0 = @adaptor.create_flat_list # at line 794:4: ( ( mutation | mutation_iterator ) ( NL )+ )* # at line 794:4: ( ( mutation | mutation_iterator ) ( NL )+ )* while true # decision 133 alt_133 = 2 look_133_0 = @input.peek( 1 ) if ( look_133_0 == ID || look_133_0 == T__54 || look_133_0 == T__69 ) alt_133 = 1 end case alt_133 when 1 # at line 795:4: ( mutation | mutation_iterator ) ( NL )+ # at line 795:4: ( mutation | mutation_iterator ) alt_131 = 2 look_131_0 = @input.peek( 1 ) if ( look_131_0 == ID || look_131_0 == T__69 ) alt_131 = 1 elsif ( look_131_0 == T__54 ) alt_131 = 2 else raise NoViableAlternative( "", 131, 0 ) end case alt_131 when 1 # at line 795:6: mutation @state.following.push( TOKENS_FOLLOWING_mutation_IN_effect_body_2221 ) mutation366 = mutation @state.following.pop @adaptor.add_child( root_0, mutation366.tree ) # --> action @now[( mutation366.nil? ? nil : mutation366.key )] = ( mutation366.nil? ? nil : mutation366.val ) # <-- action when 2 # at line 797:6: mutation_iterator @state.following.push( TOKENS_FOLLOWING_mutation_iterator_IN_effect_body_2234 ) mutation_iterator367 = mutation_iterator @state.following.pop @adaptor.add_child( root_0, mutation_iterator367.tree ) end # at file 799:3: ( NL )+ match_count_132 = 0 while true alt_132 = 2 look_132_0 = @input.peek( 1 ) if ( look_132_0 == NL ) alt_132 = 1 end case alt_132 when 1 # at line 799:3: NL __NL368__ = match( NL, TOKENS_FOLLOWING_NL_IN_effect_body_2243 ) tree_for_NL368 = @adaptor.create_with_payload( __NL368__ ) @adaptor.add_child( root_0, tree_for_NL368 ) else match_count_132 > 0 and break eee = EarlyExit(132) raise eee end match_count_132 += 1 end else break # out of loop for decision 133 end end # loop for decision 133 # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 47 ) end return return_value end MutationIteratorReturnValue = define_return_scope # # parser rule mutation_iterator # # (in SfpLang.g) # 802:1: mutation_iterator : 'foreach' path 'as' ID ( NL )* '{' ( NL )+ ( mutation ( NL )+ )* '}' ; # def mutation_iterator # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 48 ) return_value = MutationIteratorReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal369 = nil string_literal371 = nil __ID372__ = nil __NL373__ = nil char_literal374 = nil __NL375__ = nil __NL377__ = nil char_literal378 = nil path370 = nil mutation376 = nil tree_for_string_literal369 = nil tree_for_string_literal371 = nil tree_for_ID372 = nil tree_for_NL373 = nil tree_for_char_literal374 = nil tree_for_NL375 = nil tree_for_NL377 = nil tree_for_char_literal378 = nil begin root_0 = @adaptor.create_flat_list # at line 803:4: 'foreach' path 'as' ID ( NL )* '{' ( NL )+ ( mutation ( NL )+ )* '}' string_literal369 = match( T__54, TOKENS_FOLLOWING_T__54_IN_mutation_iterator_2258 ) tree_for_string_literal369 = @adaptor.create_with_payload( string_literal369 ) @adaptor.add_child( root_0, tree_for_string_literal369 ) @state.following.push( TOKENS_FOLLOWING_path_IN_mutation_iterator_2260 ) path370 = path @state.following.pop @adaptor.add_child( root_0, path370.tree ) string_literal371 = match( T__55, TOKENS_FOLLOWING_T__55_IN_mutation_iterator_2262 ) tree_for_string_literal371 = @adaptor.create_with_payload( string_literal371 ) @adaptor.add_child( root_0, tree_for_string_literal371 ) __ID372__ = match( ID, TOKENS_FOLLOWING_ID_IN_mutation_iterator_2264 ) tree_for_ID372 = @adaptor.create_with_payload( __ID372__ ) @adaptor.add_child( root_0, tree_for_ID372 ) # at line 803:27: ( NL )* while true # decision 134 alt_134 = 2 look_134_0 = @input.peek( 1 ) if ( look_134_0 == NL ) alt_134 = 1 end case alt_134 when 1 # at line 803:27: NL __NL373__ = match( NL, TOKENS_FOLLOWING_NL_IN_mutation_iterator_2266 ) tree_for_NL373 = @adaptor.create_with_payload( __NL373__ ) @adaptor.add_child( root_0, tree_for_NL373 ) else break # out of loop for decision 134 end end # loop for decision 134 char_literal374 = match( T__20, TOKENS_FOLLOWING_T__20_IN_mutation_iterator_2269 ) tree_for_char_literal374 = @adaptor.create_with_payload( char_literal374 ) @adaptor.add_child( root_0, tree_for_char_literal374 ) # at file 803:35: ( NL )+ match_count_135 = 0 while true alt_135 = 2 look_135_0 = @input.peek( 1 ) if ( look_135_0 == NL ) alt_135 = 1 end case alt_135 when 1 # at line 803:35: NL __NL375__ = match( NL, TOKENS_FOLLOWING_NL_IN_mutation_iterator_2271 ) tree_for_NL375 = @adaptor.create_with_payload( __NL375__ ) @adaptor.add_child( root_0, tree_for_NL375 ) else match_count_135 > 0 and break eee = EarlyExit(135) raise eee end match_count_135 += 1 end # --> action id = self.to_ref(( path370 && @input.to_s( path370.start, path370.stop ) )) @now[id] = { '_parent' => @now, '_context' => 'iterator', '_self' => id, '_variable' => __ID372__.text } @now = @now[id] # <-- action # at line 813:3: ( mutation ( NL )+ )* while true # decision 137 alt_137 = 2 look_137_0 = @input.peek( 1 ) if ( look_137_0 == ID || look_137_0 == T__69 ) alt_137 = 1 end case alt_137 when 1 # at line 813:4: mutation ( NL )+ @state.following.push( TOKENS_FOLLOWING_mutation_IN_mutation_iterator_2281 ) mutation376 = mutation @state.following.pop @adaptor.add_child( root_0, mutation376.tree ) # --> action @now[( mutation376.nil? ? nil : mutation376.key )] = ( mutation376.nil? ? nil : mutation376.val ) # <-- action # at file 815:3: ( NL )+ match_count_136 = 0 while true alt_136 = 2 look_136_0 = @input.peek( 1 ) if ( look_136_0 == NL ) alt_136 = 1 end case alt_136 when 1 # at line 815:3: NL __NL377__ = match( NL, TOKENS_FOLLOWING_NL_IN_mutation_iterator_2289 ) tree_for_NL377 = @adaptor.create_with_payload( __NL377__ ) @adaptor.add_child( root_0, tree_for_NL377 ) else match_count_136 > 0 and break eee = EarlyExit(136) raise eee end match_count_136 += 1 end else break # out of loop for decision 137 end end # loop for decision 137 char_literal378 = match( T__21, TOKENS_FOLLOWING_T__21_IN_mutation_iterator_2296 ) tree_for_char_literal378 = @adaptor.create_with_payload( char_literal378 ) @adaptor.add_child( root_0, tree_for_char_literal378 ) # --> action self.goto_parent() # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 48 ) end return return_value end MutationReturnValue = define_return_scope :key, :val # # parser rule mutation # # (in SfpLang.g) # 820:1: mutation returns [key, val] : ( reference equals_op value | reference equals_op NULL | reference binary_op NUMBER | reference 'is' 'new' path ( object_body )? | 'delete' path | reference 'add(' value ')' | reference 'remove(' value ')' ); # def mutation # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 49 ) return_value = MutationReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __NULL384__ = nil __NUMBER387__ = nil string_literal389 = nil string_literal390 = nil string_literal393 = nil string_literal396 = nil char_literal398 = nil string_literal400 = nil char_literal402 = nil reference379 = nil equals_op380 = nil value381 = nil reference382 = nil equals_op383 = nil reference385 = nil binary_op386 = nil reference388 = nil path391 = nil object_body392 = nil path394 = nil reference395 = nil value397 = nil reference399 = nil value401 = nil tree_for_NULL384 = nil tree_for_NUMBER387 = nil tree_for_string_literal389 = nil tree_for_string_literal390 = nil tree_for_string_literal393 = nil tree_for_string_literal396 = nil tree_for_char_literal398 = nil tree_for_string_literal400 = nil tree_for_char_literal402 = nil begin # at line 821:2: ( reference equals_op value | reference equals_op NULL | reference binary_op NUMBER | reference 'is' 'new' path ( object_body )? | 'delete' path | reference 'add(' value ')' | reference 'remove(' value ')' ) alt_139 = 7 alt_139 = @dfa139.predict( @input ) case alt_139 when 1 root_0 = @adaptor.create_flat_list # at line 821:4: reference equals_op value @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2315 ) reference379 = reference @state.following.pop @adaptor.add_child( root_0, reference379.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_mutation_2317 ) equals_op380 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op380.tree ) @state.following.push( TOKENS_FOLLOWING_value_IN_mutation_2319 ) value381 = value @state.following.pop @adaptor.add_child( root_0, value381.tree ) # --> action return_value.key = ( reference379.nil? ? nil : reference379.val ) return_value.val = { '_context' => 'mutation', '_type' => 'equals', '_value' => ( value381.nil? ? nil : value381.val ) } # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 829:4: reference equals_op NULL @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2328 ) reference382 = reference @state.following.pop @adaptor.add_child( root_0, reference382.tree ) @state.following.push( TOKENS_FOLLOWING_equals_op_IN_mutation_2330 ) equals_op383 = equals_op @state.following.pop @adaptor.add_child( root_0, equals_op383.tree ) __NULL384__ = match( NULL, TOKENS_FOLLOWING_NULL_IN_mutation_2332 ) tree_for_NULL384 = @adaptor.create_with_payload( __NULL384__ ) @adaptor.add_child( root_0, tree_for_NULL384 ) # --> action return_value.key = ( reference382.nil? ? nil : reference382.val ) return_value.val = { '_context' => 'mutation', '_type' => 'equals', '_value' => self.null_value } # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 837:4: reference binary_op NUMBER @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2341 ) reference385 = reference @state.following.pop @adaptor.add_child( root_0, reference385.tree ) @state.following.push( TOKENS_FOLLOWING_binary_op_IN_mutation_2343 ) binary_op386 = binary_op @state.following.pop @adaptor.add_child( root_0, binary_op386.tree ) __NUMBER387__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_mutation_2345 ) tree_for_NUMBER387 = @adaptor.create_with_payload( __NUMBER387__ ) @adaptor.add_child( root_0, tree_for_NUMBER387 ) # --> action return_value.key = ( reference385.nil? ? nil : reference385.val ) return_value.val = { '_context' => 'mutation', '_type' => ( binary_op386 && @input.to_s( binary_op386.start, binary_op386.stop ) ), '_value' => __NUMBER387__.text.to_i } # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 845:4: reference 'is' 'new' path ( object_body )? @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2354 ) reference388 = reference @state.following.pop @adaptor.add_child( root_0, reference388.tree ) string_literal389 = match( T__62, TOKENS_FOLLOWING_T__62_IN_mutation_2356 ) tree_for_string_literal389 = @adaptor.create_with_payload( string_literal389 ) @adaptor.add_child( root_0, tree_for_string_literal389 ) string_literal390 = match( T__68, TOKENS_FOLLOWING_T__68_IN_mutation_2358 ) tree_for_string_literal390 = @adaptor.create_with_payload( string_literal390 ) @adaptor.add_child( root_0, tree_for_string_literal390 ) @state.following.push( TOKENS_FOLLOWING_path_IN_mutation_2360 ) path391 = path @state.following.pop @adaptor.add_child( root_0, path391.tree ) # --> action id = '_' + self.next_id @now[id] = { '_self' => id, '_context' => 'object', '_isa' => self.to_ref(( path391 && @input.to_s( path391.start, path391.stop ) )), '_parent' => @now } @now = @now[id] # <-- action # at line 855:3: ( object_body )? alt_138 = 2 look_138_0 = @input.peek( 1 ) if ( look_138_0 == T__20 ) alt_138 = 1 end case alt_138 when 1 # at line 855:3: object_body @state.following.push( TOKENS_FOLLOWING_object_body_IN_mutation_2368 ) object_body392 = object_body @state.following.pop @adaptor.add_child( root_0, object_body392.tree ) end # --> action n = self.goto_parent() @now.delete(n['_self']) return_value.key = ( reference388.nil? ? nil : reference388.val ) return_value.val = n # <-- action when 5 root_0 = @adaptor.create_flat_list # at line 862:4: 'delete' path string_literal393 = match( T__69, TOKENS_FOLLOWING_T__69_IN_mutation_2378 ) tree_for_string_literal393 = @adaptor.create_with_payload( string_literal393 ) @adaptor.add_child( root_0, tree_for_string_literal393 ) @state.following.push( TOKENS_FOLLOWING_path_IN_mutation_2380 ) path394 = path @state.following.pop @adaptor.add_child( root_0, path394.tree ) # --> action id = '_' + self.next_id @now[id] = { '_self' => id, '_context' => 'mutation', '_type' => 'delete', '_value' => self.to_ref(( path394 && @input.to_s( path394.start, path394.stop ) )) } # <-- action when 6 root_0 = @adaptor.create_flat_list # at line 871:4: reference 'add(' value ')' @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2389 ) reference395 = reference @state.following.pop @adaptor.add_child( root_0, reference395.tree ) string_literal396 = match( T__70, TOKENS_FOLLOWING_T__70_IN_mutation_2391 ) tree_for_string_literal396 = @adaptor.create_with_payload( string_literal396 ) @adaptor.add_child( root_0, tree_for_string_literal396 ) @state.following.push( TOKENS_FOLLOWING_value_IN_mutation_2393 ) value397 = value @state.following.pop @adaptor.add_child( root_0, value397.tree ) char_literal398 = match( T__42, TOKENS_FOLLOWING_T__42_IN_mutation_2395 ) tree_for_char_literal398 = @adaptor.create_with_payload( char_literal398 ) @adaptor.add_child( root_0, tree_for_char_literal398 ) # --> action return_value.key = ( reference395.nil? ? nil : reference395.val ) return_value.val = { '_context' => 'mutation', '_type' => 'add', '_value' => ( value397.nil? ? nil : value397.val ) } # <-- action when 7 root_0 = @adaptor.create_flat_list # at line 879:4: reference 'remove(' value ')' @state.following.push( TOKENS_FOLLOWING_reference_IN_mutation_2404 ) reference399 = reference @state.following.pop @adaptor.add_child( root_0, reference399.tree ) string_literal400 = match( T__71, TOKENS_FOLLOWING_T__71_IN_mutation_2406 ) tree_for_string_literal400 = @adaptor.create_with_payload( string_literal400 ) @adaptor.add_child( root_0, tree_for_string_literal400 ) @state.following.push( TOKENS_FOLLOWING_value_IN_mutation_2408 ) value401 = value @state.following.pop @adaptor.add_child( root_0, value401.tree ) char_literal402 = match( T__42, TOKENS_FOLLOWING_T__42_IN_mutation_2410 ) tree_for_char_literal402 = @adaptor.create_with_payload( char_literal402 ) @adaptor.add_child( root_0, tree_for_char_literal402 ) # --> action return_value.key = ( reference399.nil? ? nil : reference399.val ) return_value.val = { '_context' => 'mutation', '_type' => 'remove', '_value' => ( value401.nil? ? nil : value401.val ) } # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 49 ) end return return_value end SetValueReturnValue = define_return_scope :val # # parser rule set_value # # (in SfpLang.g) # 889:1: set_value returns [val] : '(' ( set_item ( ',' ( NL )* set_item )* )? ')' ; # def set_value # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 50 ) return_value = SetValueReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal403 = nil char_literal405 = nil __NL406__ = nil char_literal408 = nil set_item404 = nil set_item407 = nil tree_for_char_literal403 = nil tree_for_char_literal405 = nil tree_for_NL406 = nil tree_for_char_literal408 = nil begin root_0 = @adaptor.create_flat_list # at line 890:4: '(' ( set_item ( ',' ( NL )* set_item )* )? ')' char_literal403 = match( T__41, TOKENS_FOLLOWING_T__41_IN_set_value_2429 ) tree_for_char_literal403 = @adaptor.create_with_payload( char_literal403 ) @adaptor.add_child( root_0, tree_for_char_literal403 ) # --> action @set = Array.new # <-- action # at line 892:3: ( set_item ( ',' ( NL )* set_item )* )? alt_142 = 2 look_142_0 = @input.peek( 1 ) if ( look_142_0.between?( STRING, NUMBER ) || look_142_0.between?( BOOLEAN, MULTILINE_STRING ) || look_142_0 == T__41 || look_142_0 == T__72 ) alt_142 = 1 end case alt_142 when 1 # at line 892:4: set_item ( ',' ( NL )* set_item )* @state.following.push( TOKENS_FOLLOWING_set_item_IN_set_value_2438 ) set_item404 = set_item @state.following.pop @adaptor.add_child( root_0, set_item404.tree ) # at line 892:13: ( ',' ( NL )* set_item )* while true # decision 141 alt_141 = 2 look_141_0 = @input.peek( 1 ) if ( look_141_0 == T__30 ) alt_141 = 1 end case alt_141 when 1 # at line 892:14: ',' ( NL )* set_item char_literal405 = match( T__30, TOKENS_FOLLOWING_T__30_IN_set_value_2441 ) tree_for_char_literal405 = @adaptor.create_with_payload( char_literal405 ) @adaptor.add_child( root_0, tree_for_char_literal405 ) # at line 892:18: ( NL )* while true # decision 140 alt_140 = 2 look_140_0 = @input.peek( 1 ) if ( look_140_0 == NL ) alt_140 = 1 end case alt_140 when 1 # at line 892:18: NL __NL406__ = match( NL, TOKENS_FOLLOWING_NL_IN_set_value_2443 ) tree_for_NL406 = @adaptor.create_with_payload( __NL406__ ) @adaptor.add_child( root_0, tree_for_NL406 ) else break # out of loop for decision 140 end end # loop for decision 140 @state.following.push( TOKENS_FOLLOWING_set_item_IN_set_value_2446 ) set_item407 = set_item @state.following.pop @adaptor.add_child( root_0, set_item407.tree ) else break # out of loop for decision 141 end end # loop for decision 141 end # --> action return_value.val = @set # <-- action char_literal408 = match( T__42, TOKENS_FOLLOWING_T__42_IN_set_value_2458 ) tree_for_char_literal408 = @adaptor.create_with_payload( char_literal408 ) @adaptor.add_child( root_0, tree_for_char_literal408 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 50 ) end return return_value end SetItemReturnValue = define_return_scope # # parser rule set_item # # (in SfpLang.g) # 897:1: set_item : value ; # def set_item # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 51 ) return_value = SetItemReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil value409 = nil begin root_0 = @adaptor.create_flat_list # at line 898:4: value @state.following.push( TOKENS_FOLLOWING_value_IN_set_item_2469 ) value409 = value @state.following.pop @adaptor.add_child( root_0, value409.tree ) # --> action @set.push(( value409.nil? ? nil : value409.val )) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 51 ) end return return_value end ValueReturnValue = define_return_scope :val, :type # # parser rule value # # (in SfpLang.g) # 902:1: value returns [val, type] : ( primitive_value | reference | set_value | 'any' ); # def value # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 52 ) return_value = ValueReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal413 = nil primitive_value410 = nil reference411 = nil set_value412 = nil tree_for_string_literal413 = nil begin # at line 903:2: ( primitive_value | reference | set_value | 'any' ) alt_143 = 4 case look_143 = @input.peek( 1 ) when STRING, NUMBER, BOOLEAN, MULTILINE_STRING then alt_143 = 1 when ID then alt_143 = 2 when T__41 then alt_143 = 3 when T__72 then alt_143 = 4 else raise NoViableAlternative( "", 143, 0 ) end case alt_143 when 1 root_0 = @adaptor.create_flat_list # at line 903:4: primitive_value @state.following.push( TOKENS_FOLLOWING_primitive_value_IN_value_2488 ) primitive_value410 = primitive_value @state.following.pop @adaptor.add_child( root_0, primitive_value410.tree ) # --> action return_value.val = ( primitive_value410.nil? ? nil : primitive_value410.val ) return_value.type = ( primitive_value410.nil? ? nil : primitive_value410.type ) # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 908:4: reference @state.following.push( TOKENS_FOLLOWING_reference_IN_value_2497 ) reference411 = reference @state.following.pop @adaptor.add_child( root_0, reference411.tree ) # --> action return_value.val = ( reference411.nil? ? nil : reference411.val ) return_value.type = 'Reference' # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 913:4: set_value @state.following.push( TOKENS_FOLLOWING_set_value_IN_value_2506 ) set_value412 = set_value @state.following.pop @adaptor.add_child( root_0, set_value412.tree ) # --> action return_value.val = ( set_value412.nil? ? nil : set_value412.val ) return_value.type = 'Set' # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 918:4: 'any' string_literal413 = match( T__72, TOKENS_FOLLOWING_T__72_IN_value_2515 ) tree_for_string_literal413 = @adaptor.create_with_payload( string_literal413 ) @adaptor.add_child( root_0, tree_for_string_literal413 ) # --> action return_value.val = Sfp::Any.new return_value.type = 'Any' # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 52 ) end return return_value end PrimitiveValueReturnValue = define_return_scope :val, :type # # parser rule primitive_value # # (in SfpLang.g) # 925:1: primitive_value returns [val, type] : ( BOOLEAN | NUMBER | STRING | MULTILINE_STRING ); # def primitive_value # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 53 ) return_value = PrimitiveValueReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __BOOLEAN414__ = nil __NUMBER415__ = nil __STRING416__ = nil __MULTILINE_STRING417__ = nil tree_for_BOOLEAN414 = nil tree_for_NUMBER415 = nil tree_for_STRING416 = nil tree_for_MULTILINE_STRING417 = nil begin # at line 926:2: ( BOOLEAN | NUMBER | STRING | MULTILINE_STRING ) alt_144 = 4 case look_144 = @input.peek( 1 ) when BOOLEAN then alt_144 = 1 when NUMBER then alt_144 = 2 when STRING then alt_144 = 3 when MULTILINE_STRING then alt_144 = 4 else raise NoViableAlternative( "", 144, 0 ) end case alt_144 when 1 root_0 = @adaptor.create_flat_list # at line 926:4: BOOLEAN __BOOLEAN414__ = match( BOOLEAN, TOKENS_FOLLOWING_BOOLEAN_IN_primitive_value_2534 ) tree_for_BOOLEAN414 = @adaptor.create_with_payload( __BOOLEAN414__ ) @adaptor.add_child( root_0, tree_for_BOOLEAN414 ) # --> action if __BOOLEAN414__.text == 'true' or __BOOLEAN414__.text == 'on' or __BOOLEAN414__.text == 'yes' return_value.val = true else # 'false', 'no', 'off' return_value.val = false end return_value.type = 'Boolean' # <-- action when 2 root_0 = @adaptor.create_flat_list # at line 935:4: NUMBER __NUMBER415__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_primitive_value_2543 ) tree_for_NUMBER415 = @adaptor.create_with_payload( __NUMBER415__ ) @adaptor.add_child( root_0, tree_for_NUMBER415 ) # --> action return_value.val = __NUMBER415__.text.to_i return_value.type = 'Number' # <-- action when 3 root_0 = @adaptor.create_flat_list # at line 940:4: STRING __STRING416__ = match( STRING, TOKENS_FOLLOWING_STRING_IN_primitive_value_2552 ) tree_for_STRING416 = @adaptor.create_with_payload( __STRING416__ ) @adaptor.add_child( root_0, tree_for_STRING416 ) # --> action return_value.val = __STRING416__.text[1,__STRING416__.text.length-2] return_value.type = 'String' # <-- action when 4 root_0 = @adaptor.create_flat_list # at line 945:4: MULTILINE_STRING __MULTILINE_STRING417__ = match( MULTILINE_STRING, TOKENS_FOLLOWING_MULTILINE_STRING_IN_primitive_value_2561 ) tree_for_MULTILINE_STRING417 = @adaptor.create_with_payload( __MULTILINE_STRING417__ ) @adaptor.add_child( root_0, tree_for_MULTILINE_STRING417 ) # --> action return_value.val = __MULTILINE_STRING417__.text[2, __MULTILINE_STRING417__.text.length-2] return_value.type = 'String' # <-- action end# - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 53 ) end return return_value end PathReturnValue = define_return_scope # # parser rule path # # (in SfpLang.g) # 952:1: path : ID ( '.' ID )* ; # def path # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 54 ) return_value = PathReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID418__ = nil char_literal419 = nil __ID420__ = nil tree_for_ID418 = nil tree_for_char_literal419 = nil tree_for_ID420 = nil begin root_0 = @adaptor.create_flat_list # at line 953:4: ID ( '.' ID )* __ID418__ = match( ID, TOKENS_FOLLOWING_ID_IN_path_2576 ) tree_for_ID418 = @adaptor.create_with_payload( __ID418__ ) @adaptor.add_child( root_0, tree_for_ID418 ) # at line 953:6: ( '.' ID )* while true # decision 145 alt_145 = 2 look_145_0 = @input.peek( 1 ) if ( look_145_0 == T__73 ) alt_145 = 1 end case alt_145 when 1 # at line 953:7: '.' ID char_literal419 = match( T__73, TOKENS_FOLLOWING_T__73_IN_path_2578 ) tree_for_char_literal419 = @adaptor.create_with_payload( char_literal419 ) @adaptor.add_child( root_0, tree_for_char_literal419 ) __ID420__ = match( ID, TOKENS_FOLLOWING_ID_IN_path_2579 ) tree_for_ID420 = @adaptor.create_with_payload( __ID420__ ) @adaptor.add_child( root_0, tree_for_ID420 ) else break # out of loop for decision 145 end end # loop for decision 145 # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 54 ) end return return_value end PathWithIndexReturnValue = define_return_scope # # parser rule path_with_index # # (in SfpLang.g) # 956:1: path_with_index : id_ref ( '.' id_ref )* ; # def path_with_index # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 55 ) return_value = PathWithIndexReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil char_literal422 = nil id_ref421 = nil id_ref423 = nil tree_for_char_literal422 = nil begin root_0 = @adaptor.create_flat_list # at line 957:4: id_ref ( '.' id_ref )* @state.following.push( TOKENS_FOLLOWING_id_ref_IN_path_with_index_2592 ) id_ref421 = id_ref @state.following.pop @adaptor.add_child( root_0, id_ref421.tree ) # at line 957:10: ( '.' id_ref )* while true # decision 146 alt_146 = 2 look_146_0 = @input.peek( 1 ) if ( look_146_0 == T__73 ) alt_146 = 1 end case alt_146 when 1 # at line 957:11: '.' id_ref char_literal422 = match( T__73, TOKENS_FOLLOWING_T__73_IN_path_with_index_2594 ) tree_for_char_literal422 = @adaptor.create_with_payload( char_literal422 ) @adaptor.add_child( root_0, tree_for_char_literal422 ) @state.following.push( TOKENS_FOLLOWING_id_ref_IN_path_with_index_2595 ) id_ref423 = id_ref @state.following.pop @adaptor.add_child( root_0, id_ref423.tree ) else break # out of loop for decision 146 end end # loop for decision 146 # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 55 ) end return return_value end IdRefReturnValue = define_return_scope # # parser rule id_ref # # (in SfpLang.g) # 960:1: id_ref : ID ( '[' NUMBER ']' )? ; # def id_ref # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 56 ) return_value = IdRefReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil __ID424__ = nil char_literal425 = nil __NUMBER426__ = nil char_literal427 = nil tree_for_ID424 = nil tree_for_char_literal425 = nil tree_for_NUMBER426 = nil tree_for_char_literal427 = nil begin root_0 = @adaptor.create_flat_list # at line 961:4: ID ( '[' NUMBER ']' )? __ID424__ = match( ID, TOKENS_FOLLOWING_ID_IN_id_ref_2608 ) tree_for_ID424 = @adaptor.create_with_payload( __ID424__ ) @adaptor.add_child( root_0, tree_for_ID424 ) # at line 961:6: ( '[' NUMBER ']' )? alt_147 = 2 look_147_0 = @input.peek( 1 ) if ( look_147_0 == T__28 ) alt_147 = 1 end case alt_147 when 1 # at line 961:7: '[' NUMBER ']' char_literal425 = match( T__28, TOKENS_FOLLOWING_T__28_IN_id_ref_2610 ) tree_for_char_literal425 = @adaptor.create_with_payload( char_literal425 ) @adaptor.add_child( root_0, tree_for_char_literal425 ) __NUMBER426__ = match( NUMBER, TOKENS_FOLLOWING_NUMBER_IN_id_ref_2612 ) tree_for_NUMBER426 = @adaptor.create_with_payload( __NUMBER426__ ) @adaptor.add_child( root_0, tree_for_NUMBER426 ) char_literal427 = match( T__29, TOKENS_FOLLOWING_T__29_IN_id_ref_2614 ) tree_for_char_literal427 = @adaptor.create_with_payload( char_literal427 ) @adaptor.add_child( root_0, tree_for_char_literal427 ) end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 56 ) end return return_value end ReferenceReturnValue = define_return_scope :val # # parser rule reference # # (in SfpLang.g) # 964:1: reference returns [val] : path_with_index ; # def reference # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 57 ) return_value = ReferenceReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil path_with_index428 = nil begin root_0 = @adaptor.create_flat_list # at line 965:4: path_with_index @state.following.push( TOKENS_FOLLOWING_path_with_index_IN_reference_2631 ) path_with_index428 = path_with_index @state.following.pop @adaptor.add_child( root_0, path_with_index428.tree ) # --> action return_value.val = self.to_ref(( path_with_index428 && @input.to_s( path_with_index428.start, path_with_index428.stop ) )) # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 57 ) end return return_value end ReferenceTypeReturnValue = define_return_scope :val # # parser rule reference_type # # (in SfpLang.g) # 969:1: reference_type returns [val] : 'isref' path ; # def reference_type # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 58 ) return_value = ReferenceTypeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal429 = nil path430 = nil tree_for_string_literal429 = nil begin root_0 = @adaptor.create_flat_list # at line 970:4: 'isref' path string_literal429 = match( T__74, TOKENS_FOLLOWING_T__74_IN_reference_type_2650 ) tree_for_string_literal429 = @adaptor.create_with_payload( string_literal429 ) @adaptor.add_child( root_0, tree_for_string_literal429 ) @state.following.push( TOKENS_FOLLOWING_path_IN_reference_type_2652 ) path430 = path @state.following.pop @adaptor.add_child( root_0, path430.tree ) # --> action return_value.val = { '_context' => 'null', '_isa' => self.to_ref(( path430 && @input.to_s( path430.start, path430.stop ) )) } # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 58 ) end return return_value end SetTypeReturnValue = define_return_scope :val # # parser rule set_type # # (in SfpLang.g) # 978:1: set_type returns [val] : 'isset' path ; # def set_type # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 59 ) return_value = SetTypeReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal431 = nil path432 = nil tree_for_string_literal431 = nil begin root_0 = @adaptor.create_flat_list # at line 979:4: 'isset' path string_literal431 = match( T__44, TOKENS_FOLLOWING_T__44_IN_set_type_2671 ) tree_for_string_literal431 = @adaptor.create_with_payload( string_literal431 ) @adaptor.add_child( root_0, tree_for_string_literal431 ) @state.following.push( TOKENS_FOLLOWING_path_IN_set_type_2673 ) path432 = path @state.following.pop @adaptor.add_child( root_0, path432.tree ) # --> action return_value.val = { '_context' => 'set', '_isa' => self.to_ref(( path432 && @input.to_s( path432.start, path432.stop ) )), '_values' => [] } # <-- action # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 59 ) end return return_value end ProbabilityOpReturnValue = define_return_scope # # parser rule probability_op # # (in SfpLang.g) # 988:1: probability_op : 'either' ; # def probability_op # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 60 ) return_value = ProbabilityOpReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil string_literal433 = nil tree_for_string_literal433 = nil begin root_0 = @adaptor.create_flat_list # at line 989:4: 'either' string_literal433 = match( T__75, TOKENS_FOLLOWING_T__75_IN_probability_op_2688 ) tree_for_string_literal433 = @adaptor.create_with_payload( string_literal433 ) @adaptor.add_child( root_0, tree_for_string_literal433 ) # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 60 ) end return return_value end EqualsOpReturnValue = define_return_scope # # parser rule equals_op # # (in SfpLang.g) # 992:1: equals_op : ( '=' | 'is' ); # def equals_op # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 61 ) return_value = EqualsOpReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set434 = nil tree_for_set434 = nil begin root_0 = @adaptor.create_flat_list # at line set434 = @input.look if @input.peek(1) == T__59 || @input.peek(1) == T__62 @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set434 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 61 ) end return return_value end NotEqualsOpReturnValue = define_return_scope # # parser rule not_equals_op # # (in SfpLang.g) # 997:1: not_equals_op : ( '!=' | 'isnt' | 'isnot' ); # def not_equals_op # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 62 ) return_value = NotEqualsOpReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set435 = nil tree_for_set435 = nil begin root_0 = @adaptor.create_flat_list # at line set435 = @input.look if @input.peek( 1 ).between?( T__64, T__65 ) || @input.peek(1) == T__76 @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set435 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 62 ) end return return_value end BinaryOpReturnValue = define_return_scope # # parser rule binary_op # # (in SfpLang.g) # 1003:1: binary_op : ( '+=' | '-=' | '*=' | '/=' ); # def binary_op # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 63 ) return_value = BinaryOpReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set436 = nil tree_for_set436 = nil begin root_0 = @adaptor.create_flat_list # at line set436 = @input.look if @input.peek( 1 ).between?( T__77, T__80 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set436 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 63 ) end return return_value end BinaryCompReturnValue = define_return_scope # # parser rule binary_comp # # (in SfpLang.g) # 1010:1: binary_comp : ( '>' | '>=' | '<' | '<=' ); # def binary_comp # -> uncomment the next line to manually enable rule tracing # trace_in( __method__, 64 ) return_value = BinaryCompReturnValue.new # $rule.start = the first token seen before matching return_value.start = @input.look root_0 = nil set437 = nil tree_for_set437 = nil begin root_0 = @adaptor.create_flat_list # at line set437 = @input.look if @input.peek( 1 ).between?( T__81, T__84 ) @input.consume @adaptor.add_child( root_0, @adaptor.create_with_payload( set437 ) ) @state.error_recovery = false else mse = MismatchedSet( nil ) raise mse end # - - - - - - - rule clean up - - - - - - - - return_value.stop = @input.look( -1 ) return_value.tree = @adaptor.rule_post_processing( root_0 ) @adaptor.set_token_boundaries( return_value.tree, return_value.start, return_value.stop ) rescue ANTLR3::Error::RecognitionError => re report_error(re) recover(re) return_value.tree = @adaptor.create_error_node( @input, return_value.start, @input.look(-1), re ) ensure # -> uncomment the next line to manually enable rule tracing # trace_out( __method__, 64 ) end return return_value end # - - - - - - - - - - DFA definitions - - - - - - - - - - - class DFA42 < ANTLR3::DFA EOT = unpack( 4, -1 ) EOF = unpack( 1, -1, 1, 3, 2, -1 ) MIN = unpack( 2, 4, 2, -1 ) MAX = unpack( 2, 34, 2, -1 ) ACCEPT = unpack( 2, -1, 1, 1, 1, 2 ) SPECIAL = unpack( 4, -1 ) TRANSITION = [ unpack( 1, 1, 29, -1, 1, 2 ), unpack( 1, 1, 29, -1, 1, 2 ), unpack( ), unpack( ) ].freeze ( 0 ... MIN.length ).zip( MIN, MAX ) do | i, a, z | if a > 0 and z < 0 MAX[ i ] %= 0x10000 end end @decision = 42 def description <<-'__dfa_description__'.strip! ()* loopback of 287:3: ( ( NL )* 'or' ( NL )* '{' ( NL )* constraint_body '}' )* __dfa_description__ end end class DFA76 < ANTLR3::DFA EOT = unpack( 9, -1 ) EOF = unpack( 9, -1 ) MIN = unpack( 1, 6, 1, 4, 3, -1, 1, 6, 1, 4, 1, -1, 1, 4 ) MAX = unpack( 1, 67, 1, 84, 3, -1, 1, 6, 1, 67, 1, -1, 1, 84 ) ACCEPT = unpack( 2, -1, 1, 1, 1, 3, 1, 4, 2, -1, 1, 2, 1, -1 ) SPECIAL = unpack( 9, -1 ) TRANSITION = [ unpack( 1, 1, 25, -1, 1, 2, 21, -1, 1, 3, 1, -1, 3, 4, 2, -1, 1, 2, 5, -1, 1, 2 ), unpack( 1, 6, 15, -1, 1, 7, 7, -1, 1, 2, 30, -1, 1, 2, 1, -1, 6, 2, 6, -1, 1, 5, 2, -1, 1, 2, 4, -1, 4, 2 ), unpack( ), unpack( ), unpack( ), unpack( 1, 8 ), unpack( 1, 6, 1, -1, 1, 2, 13, -1, 1, 7, 1, 2, 10, -1, 1, 2, 15, -1, 7, 2, 1, -1, 3, 2, 2, -1, 1, 2, 5, -1, 1, 2 ), unpack( ), unpack( 1, 6, 15, -1, 1, 7, 7, -1, 1, 2, 30, -1, 1, 2, 1, -1, 6, 2, 6, -1, 1, 5, 2, -1, 1, 2, 4, -1, 4, 2 ) ].freeze ( 0 ... MIN.length ).zip( MIN, MAX ) do | i, a, z | if a > 0 and z < 0 MAX[ i ] %= 0x10000 end end @decision = 76 def description <<-'__dfa_description__'.strip! 446:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) __dfa_description__ end end class DFA103 < ANTLR3::DFA EOT = unpack( 9, -1 ) EOF = unpack( 9, -1 ) MIN = unpack( 1, 6, 1, 4, 3, -1, 1, 6, 1, 4, 1, -1, 1, 4 ) MAX = unpack( 1, 67, 1, 84, 3, -1, 1, 6, 1, 67, 1, -1, 1, 84 ) ACCEPT = unpack( 2, -1, 1, 1, 1, 3, 1, 4, 2, -1, 1, 2, 1, -1 ) SPECIAL = unpack( 9, -1 ) TRANSITION = [ unpack( 1, 1, 25, -1, 1, 2, 21, -1, 1, 3, 1, -1, 3, 4, 2, -1, 1, 2, 5, -1, 1, 2 ), unpack( 1, 6, 15, -1, 1, 7, 7, -1, 1, 2, 30, -1, 1, 2, 1, -1, 6, 2, 6, -1, 1, 5, 2, -1, 1, 2, 4, -1, 4, 2 ), unpack( ), unpack( ), unpack( ), unpack( 1, 8 ), unpack( 1, 6, 1, -1, 1, 2, 13, -1, 1, 7, 1, 2, 10, -1, 1, 2, 21, -1, 1, 2, 1, -1, 3, 2, 2, -1, 1, 2, 5, -1, 1, 2 ), unpack( ), unpack( 1, 6, 15, -1, 1, 7, 7, -1, 1, 2, 30, -1, 1, 2, 1, -1, 6, 2, 6, -1, 1, 5, 2, -1, 1, 2, 4, -1, 4, 2 ) ].freeze ( 0 ... MIN.length ).zip( MIN, MAX ) do | i, a, z | if a > 0 and z < 0 MAX[ i ] %= 0x10000 end end @decision = 103 def description <<-'__dfa_description__'.strip! 547:4: ( constraint_statement | constraint_namespace | constraint_iterator | constraint_class_quantification ) __dfa_description__ end end class DFA123 < ANTLR3::DFA EOT = unpack( 26, -1 ) EOF = unpack( 26, -1 ) MIN = unpack( 1, 6, 1, 4, 3, -1, 1, 7, 1, 6, 1, -1, 3, 5, 1, -1, 1, 5, 3, -1, 1, 29, 1, 4, 4, -1, 1, 4, 1, 7, 1, 29, 1, 4 ) MAX = unpack( 1, 67, 1, 84, 3, -1, 1, 7, 1, 6, 1, -1, 3, 72, 1, -1, 1, 72, 3, -1, 1, 29, 1, 84, 4, -1, 1, 84, 1, 7, 1, 29, 1, 84 ) ACCEPT = unpack( 2, -1, 1, 2, 1, 7, 1, 12, 2, -1, 1, 1, 3, -1, 1, 8, 1, -1, 1, 9, 1, 10, 1, 11, 2, -1, 1, 3, 1, 4, 1, 5, 1, 6, 4, -1 ) SPECIAL = unpack( 26, -1 ) TRANSITION = [ unpack( 1, 1, 25, -1, 1, 3, 28, -1, 1, 2, 5, -1, 1, 4 ), unpack( 1, 7, 23, -1, 1, 5, 4, -1, 1, 7, 25, -1, 1, 10, 1, -1, 1, 13, 1, 8, 1, 11, 2, 9, 1, 14, 6, -1, 1, 6, 2, -1, 1, 12, 4, -1, 4, 15 ), unpack( ), unpack( ), unpack( ), unpack( 1, 16 ), unpack( 1, 17 ), unpack( ), unpack( 3, 18, 1, 19, 2, 18, 30, -1, 1, 18, 21, -1, 1, 11, 8, -1, 1, 18 ), unpack( 3, 20, 1, 21, 2, 20, 30, -1, 1, 20, 21, -1, 1, 13, 8, -1, 1, 20 ), unpack( 3, 18, 1, 19, 2, 18, 30, -1, 1, 18, 30, -1, 1, 18 ), unpack( ), unpack( 3, 20, 1, 21, 2, 20, 30, -1, 1, 20, 30, -1, 1, 20 ), unpack( ), unpack( ), unpack( ), unpack( 1, 22 ), unpack( 1, 7, 23, -1, 1, 23, 4, -1, 1, 7, 25, -1, 1, 10, 1, -1, 1, 13, 1, 8, 1, 11, 2, 9, 1, 14, 6, -1, 1, 6, 2, -1, 1, 12, 4, -1, 4, 15 ), unpack( ), unpack( ), unpack( ), unpack( ), unpack( 1, 7, 28, -1, 1, 7, 25, -1, 1, 10, 1, -1, 1, 13, 1, 8, 1, 11, 2, 9, 1, 14, 6, -1, 1, 6, 2, -1, 1, 12, 4, -1, 4, 15 ), unpack( 1, 24 ), unpack( 1, 25 ), unpack( 1, 7, 28, -1, 1, 7, 25, -1, 1, 10, 1, -1, 1, 13, 1, 8, 1, 11, 2, 9, 1, 14, 6, -1, 1, 6, 2, -1, 1, 12, 4, -1, 4, 15 ) ].freeze ( 0 ... MIN.length ).zip( MIN, MAX ) do | i, a, z | if a > 0 and z < 0 MAX[ i ] %= 0x10000 end end @decision = 123 def description <<-'__dfa_description__'.strip! 647:1: constraint_statement returns [key, val] : ( reference | 'not' reference | reference equals_op value | reference equals_op NULL | reference not_equals_op value | reference not_equals_op NULL | conditional_constraint | reference ( 'is' )? 'in' set_value | reference ( 'isnot' | 'isnt' | 'not' ) 'in' set_value | reference 'has' value | reference binary_comp comp_value | total_constraint ); __dfa_description__ end end class DFA139 < ANTLR3::DFA EOT = unpack( 19, -1 ) EOF = unpack( 19, -1 ) MIN = unpack( 1, 6, 1, 28, 1, -1, 1, 7, 1, 6, 1, 5, 1, -1, 1, 5, 2, -1, 1, 29, 1, 28, 3, -1, 1, 59, 1, 7, 1, 29, 1, 59 ) MAX = unpack( 1, 69, 1, 80, 1, -1, 1, 7, 1, 6, 1, 72, 1, -1, 1, 72, 2, -1, 1, 29, 1, 80, 3, -1, 1, 80, 1, 7, 1, 29, 1, 80 ) ACCEPT = unpack( 2, -1, 1, 5, 3, -1, 1, 3, 1, -1, 1, 6, 1, 7, 2, -1, 1, 4, 1, 1, 1, 2, 4, -1 ) SPECIAL = unpack( 19, -1 ) TRANSITION = [ unpack( 1, 1, 62, -1, 1, 2 ), unpack( 1, 3, 30, -1, 1, 7, 2, -1, 1, 5, 7, -1, 1, 8, 1, 9, 1, -1, 1, 4, 3, -1, 4, 6 ), unpack( ), unpack( 1, 10 ), unpack( 1, 11 ), unpack( 3, 13, 1, 14, 2, 13, 30, -1, 1, 13, 26, -1, 1, 12, 3, -1, 1, 13 ), unpack( ), unpack( 3, 13, 1, 14, 2, 13, 30, -1, 1, 13, 30, -1, 1, 13 ), unpack( ), unpack( ), unpack( 1, 15 ), unpack( 1, 16, 30, -1, 1, 7, 2, -1, 1, 5, 7, -1, 1, 8, 1, 9, 1, -1, 1, 4, 3, -1, 4, 6 ), unpack( ), unpack( ), unpack( ), unpack( 1, 7, 2, -1, 1, 5, 7, -1, 1, 8, 1, 9, 1, -1, 1, 4, 3, -1, 4, 6 ), unpack( 1, 17 ), unpack( 1, 18 ), unpack( 1, 7, 2, -1, 1, 5, 7, -1, 1, 8, 1, 9, 1, -1, 1, 4, 3, -1, 4, 6 ) ].freeze ( 0 ... MIN.length ).zip( MIN, MAX ) do | i, a, z | if a > 0 and z < 0 MAX[ i ] %= 0x10000 end end @decision = 139 def description <<-'__dfa_description__'.strip! 820:1: mutation returns [key, val] : ( reference equals_op value | reference equals_op NULL | reference binary_op NUMBER | reference 'is' 'new' path ( object_body )? | 'delete' path | reference 'add(' value ')' | reference 'remove(' value ')' ); __dfa_description__ end end private def initialize_dfas super rescue nil @dfa42 = DFA42.new( self, 42 ) @dfa76 = DFA76.new( self, 76 ) @dfa103 = DFA103.new( self, 103 ) @dfa123 = DFA123.new( self, 123 ) @dfa139 = DFA139.new( self, 139 ) end TOKENS_FOLLOWING_NL_IN_sfp_49 = Set[ 1, 4, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_object_def_IN_sfp_60 = Set[ 1, 4, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_state_IN_sfp_64 = Set[ 1, 4, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_constraints_IN_sfp_68 = Set[ 1, 4, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_NL_IN_sfp_71 = Set[ 1, 4, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_include_IN_sfp_76 = Set[ 1, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_class_def_IN_sfp_80 = Set[ 1, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_procedure_IN_sfp_84 = Set[ 1, 6, 18, 23, 24, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_goal_constraint_IN_constraints_101 = Set[ 1 ] TOKENS_FOLLOWING_global_constraint_IN_constraints_106 = Set[ 1 ] TOKENS_FOLLOWING_sometime_constraint_IN_constraints_111 = Set[ 1 ] TOKENS_FOLLOWING_T__18_IN_include_125 = Set[ 5 ] TOKENS_FOLLOWING_include_file_IN_include_127 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_include_129 = Set[ 1, 4 ] TOKENS_FOLLOWING_STRING_IN_include_file_141 = Set[ 1 ] TOKENS_FOLLOWING_class_def_IN_header_157 = Set[ 1 ] TOKENS_FOLLOWING_procedure_IN_header_162 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_state_173 = Set[ 19 ] TOKENS_FOLLOWING_T__19_IN_state_175 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_state_177 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_state_186 = Set[ 4, 6, 21, 26 ] TOKENS_FOLLOWING_NL_IN_state_188 = Set[ 4, 6, 21, 26 ] TOKENS_FOLLOWING_attribute_IN_state_193 = Set[ 6, 21, 26 ] TOKENS_FOLLOWING_T__21_IN_state_198 = Set[ 1 ] TOKENS_FOLLOWING_T__22_IN_composite_213 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_composite_215 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_composite_223 = Set[ 4, 6, 21, 26, 47 ] TOKENS_FOLLOWING_NL_IN_composite_225 = Set[ 4, 6, 21, 26, 47 ] TOKENS_FOLLOWING_attribute_IN_composite_230 = Set[ 6, 21, 26, 47 ] TOKENS_FOLLOWING_constraint_IN_composite_234 = Set[ 6, 21, 26, 47 ] TOKENS_FOLLOWING_T__21_IN_composite_239 = Set[ 1, 4 ] TOKENS_FOLLOWING_NL_IN_composite_241 = Set[ 1, 4 ] TOKENS_FOLLOWING_set_IN_class_def_257 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_class_def_263 = Set[ 1, 4, 20, 25 ] TOKENS_FOLLOWING_extends_class_IN_class_def_272 = Set[ 1, 4, 20 ] TOKENS_FOLLOWING_T__20_IN_class_def_286 = Set[ 4, 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_NL_IN_class_def_288 = Set[ 4, 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_attribute_IN_class_def_293 = Set[ 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_procedure_IN_class_def_297 = Set[ 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_T__21_IN_class_def_302 = Set[ 1, 4 ] TOKENS_FOLLOWING_NL_IN_class_def_306 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__25_IN_extends_class_327 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_extends_class_329 = Set[ 1 ] TOKENS_FOLLOWING_T__26_IN_attribute_349 = Set[ 6, 26 ] TOKENS_FOLLOWING_attribute_stmt_IN_attribute_355 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_attribute_stmt_374 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_attribute_stmt_376 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_attribute_stmt_378 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_380 = Set[ 1, 4 ] TOKENS_FOLLOWING_ID_IN_attribute_stmt_390 = Set[ 74 ] TOKENS_FOLLOWING_reference_type_IN_attribute_stmt_392 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_394 = Set[ 1, 4 ] TOKENS_FOLLOWING_ID_IN_attribute_stmt_404 = Set[ 44 ] TOKENS_FOLLOWING_set_type_IN_attribute_stmt_406 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_408 = Set[ 1, 4 ] TOKENS_FOLLOWING_ID_IN_attribute_stmt_418 = Set[ 75 ] TOKENS_FOLLOWING_probability_op_IN_attribute_stmt_420 = Set[ 41 ] TOKENS_FOLLOWING_set_value_IN_attribute_stmt_422 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_424 = Set[ 1, 4 ] TOKENS_FOLLOWING_ID_IN_attribute_stmt_434 = Set[ 27 ] TOKENS_FOLLOWING_T__27_IN_attribute_stmt_436 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_attribute_stmt_438 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_440 = Set[ 1, 4 ] TOKENS_FOLLOWING_object_def_IN_attribute_stmt_450 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_attribute_stmt_452 = Set[ 1, 4 ] TOKENS_FOLLOWING_path_IN_object_schema_468 = Set[ 1, 28 ] TOKENS_FOLLOWING_T__28_IN_object_schema_470 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_object_schema_472 = Set[ 29 ] TOKENS_FOLLOWING_T__29_IN_object_schema_476 = Set[ 1 ] TOKENS_FOLLOWING_T__30_IN_object_schemata_493 = Set[ 6 ] TOKENS_FOLLOWING_object_schema_IN_object_schemata_495 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_object_def_510 = Set[ 1, 20, 25, 31 ] TOKENS_FOLLOWING_T__25_IN_object_def_515 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_object_def_517 = Set[ 1, 20, 31 ] TOKENS_FOLLOWING_T__31_IN_object_def_535 = Set[ 6 ] TOKENS_FOLLOWING_object_schema_IN_object_def_537 = Set[ 1, 20, 30 ] TOKENS_FOLLOWING_object_schemata_IN_object_def_540 = Set[ 1, 20, 30 ] TOKENS_FOLLOWING_object_body_IN_object_def_549 = Set[ 1 ] TOKENS_FOLLOWING_T__20_IN_object_body_565 = Set[ 4, 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_NL_IN_object_body_567 = Set[ 4, 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_object_attribute_IN_object_body_572 = Set[ 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_procedure_IN_object_body_576 = Set[ 6, 18, 21, 23, 24, 26, 38, 39, 46, 48, 49, 50 ] TOKENS_FOLLOWING_T__21_IN_object_body_581 = Set[ 1 ] TOKENS_FOLLOWING_attribute_IN_object_attribute_592 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_object_attribute_597 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_object_attribute_599 = Set[ 8 ] TOKENS_FOLLOWING_NULL_IN_object_attribute_601 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_object_attribute_603 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__32_IN_state_dependency_619 = Set[ 6 ] TOKENS_FOLLOWING_dep_effect_IN_state_dependency_623 = Set[ 4, 33 ] TOKENS_FOLLOWING_NL_IN_state_dependency_625 = Set[ 4, 33 ] TOKENS_FOLLOWING_T__33_IN_state_dependency_628 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_state_dependency_630 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_state_dependency_633 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_state_dependency_637 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_state_dependency_640 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_state_dependency_645 = Set[ 4, 34 ] TOKENS_FOLLOWING_NL_IN_state_dependency_651 = Set[ 4, 34 ] TOKENS_FOLLOWING_T__34_IN_state_dependency_654 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_state_dependency_656 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_state_dependency_659 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_state_dependency_663 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_state_dependency_666 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_state_dependency_670 = Set[ 4, 34 ] TOKENS_FOLLOWING_NL_IN_state_dependency_676 = Set[ 1, 4 ] TOKENS_FOLLOWING_reference_IN_dep_effect_688 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_dep_effect_690 = Set[ 5, 6, 7, 8, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_dep_effect_697 = Set[ 1 ] TOKENS_FOLLOWING_NULL_IN_dep_effect_703 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_op_param_719 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_op_param_721 = Set[ 6 ] TOKENS_FOLLOWING_reference_IN_op_param_723 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_op_param_725 = Set[ 1, 4 ] TOKENS_FOLLOWING_set_IN_op_conditions_741 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_op_conditions_749 = Set[ 4, 6, 21 ] TOKENS_FOLLOWING_NL_IN_op_conditions_751 = Set[ 4, 6, 21 ] TOKENS_FOLLOWING_op_statement_IN_op_conditions_760 = Set[ 6, 21 ] TOKENS_FOLLOWING_T__21_IN_op_conditions_765 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_op_conditions_767 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__37_IN_op_effects_783 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_op_effects_785 = Set[ 4, 6, 21 ] TOKENS_FOLLOWING_NL_IN_op_effects_787 = Set[ 4, 6, 21 ] TOKENS_FOLLOWING_op_statement_IN_op_effects_796 = Set[ 6, 21 ] TOKENS_FOLLOWING_T__21_IN_op_effects_801 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_op_effects_803 = Set[ 1, 4 ] TOKENS_FOLLOWING_reference_IN_op_statement_819 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_op_statement_821 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_op_statement_823 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_op_statement_825 = Set[ 1, 4 ] TOKENS_FOLLOWING_set_IN_procedure_841 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_procedure_847 = Set[ 20, 41 ] TOKENS_FOLLOWING_parameters_IN_procedure_855 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_procedure_858 = Set[ 4, 35, 36, 37, 40, 45 ] TOKENS_FOLLOWING_NL_IN_procedure_860 = Set[ 4, 35, 36, 37, 40, 45 ] TOKENS_FOLLOWING_T__40_IN_procedure_868 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_procedure_870 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_procedure_872 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_procedure_882 = Set[ 4, 35, 36, 37, 40, 45 ] TOKENS_FOLLOWING_conditions_IN_procedure_892 = Set[ 4, 35, 36, 37, 40, 45 ] TOKENS_FOLLOWING_effects_IN_procedure_895 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_procedure_897 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_procedure_899 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__41_IN_parameters_915 = Set[ 6 ] TOKENS_FOLLOWING_parameter_IN_parameters_917 = Set[ 30, 42 ] TOKENS_FOLLOWING_T__30_IN_parameters_920 = Set[ 4, 6 ] TOKENS_FOLLOWING_NL_IN_parameters_922 = Set[ 4, 6 ] TOKENS_FOLLOWING_parameter_IN_parameters_925 = Set[ 30, 42 ] TOKENS_FOLLOWING_T__42_IN_parameters_929 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_parameter_941 = Set[ 27 ] TOKENS_FOLLOWING_T__27_IN_parameter_943 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_parameter_945 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_parameter_954 = Set[ 74 ] TOKENS_FOLLOWING_reference_type_IN_parameter_956 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_parameter_965 = Set[ 43 ] TOKENS_FOLLOWING_T__43_IN_parameter_967 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_parameter_969 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_parameter_978 = Set[ 44 ] TOKENS_FOLLOWING_T__44_IN_parameter_980 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_parameter_982 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_conditions_997 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_conditions_1011 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_conditions_1013 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_conditions_1016 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_conditions_1018 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_conditions_1020 = Set[ 1, 4 ] TOKENS_FOLLOWING_set_IN_effects_1037 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_effects_1051 = Set[ 4, 6, 21, 54, 69 ] TOKENS_FOLLOWING_NL_IN_effects_1053 = Set[ 4, 6, 21, 54, 69 ] TOKENS_FOLLOWING_effect_body_IN_effects_1059 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_effects_1064 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_effects_1066 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__46_IN_goal_constraint_1082 = Set[ 4, 20, 47 ] TOKENS_FOLLOWING_T__47_IN_goal_constraint_1084 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_constraint_1087 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_constraint_1096 = Set[ 4, 6, 21, 32, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_constraint_1098 = Set[ 4, 6, 21, 32, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_goal_body_IN_goal_constraint_1101 = Set[ 6, 21, 32, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_T__21_IN_goal_constraint_1104 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_global_constraint_1119 = Set[ 4, 20, 47 ] TOKENS_FOLLOWING_T__47_IN_global_constraint_1125 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_global_constraint_1128 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_global_constraint_1137 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_global_constraint_1139 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_global_constraint_1142 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_global_constraint_1144 = Set[ 1 ] TOKENS_FOLLOWING_T__50_IN_sometime_constraint_1159 = Set[ 4, 20, 47 ] TOKENS_FOLLOWING_T__47_IN_sometime_constraint_1161 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_sometime_constraint_1164 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_sometime_constraint_1173 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_sometime_constraint_1175 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_sometime_constraint_1178 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_sometime_constraint_1180 = Set[ 1 ] TOKENS_FOLLOWING_constraint_statement_IN_goal_body_1203 = Set[ 4 ] TOKENS_FOLLOWING_constraint_namespace_IN_goal_body_1216 = Set[ 4 ] TOKENS_FOLLOWING_constraint_iterator_IN_goal_body_1223 = Set[ 4 ] TOKENS_FOLLOWING_constraint_class_quantification_IN_goal_body_1230 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1239 = Set[ 1, 4 ] TOKENS_FOLLOWING_set_IN_goal_body_1246 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1252 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1261 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1263 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1266 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1268 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1270 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__50_IN_goal_body_1280 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1282 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1291 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1293 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1296 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1298 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1300 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__51_IN_goal_body_1314 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_goal_body_1316 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1318 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1327 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1329 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1332 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1334 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1336 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__52_IN_goal_body_1346 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1348 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1357 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1359 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1362 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1364 = Set[ 4, 33, 51 ] TOKENS_FOLLOWING_NL_IN_goal_body_1366 = Set[ 4, 33, 51 ] TOKENS_FOLLOWING_T__33_IN_goal_body_1377 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__51_IN_goal_body_1384 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_goal_body_1386 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1398 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1407 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1409 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1412 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1414 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1416 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__53_IN_goal_body_1434 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1436 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1445 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1447 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1450 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1452 = Set[ 4, 33 ] TOKENS_FOLLOWING_NL_IN_goal_body_1454 = Set[ 4, 33 ] TOKENS_FOLLOWING_T__33_IN_goal_body_1463 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_goal_body_1465 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_goal_body_1474 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_goal_body_1476 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_goal_body_1479 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_goal_body_1481 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_goal_body_1483 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__20_IN_nested_constraint_1503 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_nested_constraint_1505 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_nested_constraint_1508 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_nested_constraint_1510 = Set[ 1 ] TOKENS_FOLLOWING_T__47_IN_constraint_1521 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_constraint_1523 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_constraint_1531 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_NL_IN_constraint_1533 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_constraint_1536 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_constraint_1538 = Set[ 1 ] TOKENS_FOLLOWING_constraint_statement_IN_constraint_body_1560 = Set[ 4 ] TOKENS_FOLLOWING_constraint_namespace_IN_constraint_body_1573 = Set[ 4 ] TOKENS_FOLLOWING_constraint_iterator_IN_constraint_body_1580 = Set[ 4 ] TOKENS_FOLLOWING_constraint_class_quantification_IN_constraint_body_1587 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_body_1596 = Set[ 1, 4, 6, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_path_IN_constraint_namespace_1610 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_constraint_namespace_1612 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_constraint_namespace_1615 = Set[ 4, 6, 21, 32, 61, 67 ] TOKENS_FOLLOWING_NL_IN_constraint_namespace_1617 = Set[ 4, 6, 21, 32, 61, 67 ] TOKENS_FOLLOWING_constraint_statement_IN_constraint_namespace_1621 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_namespace_1629 = Set[ 4, 6, 21, 32, 61, 67 ] TOKENS_FOLLOWING_T__21_IN_constraint_namespace_1634 = Set[ 1 ] TOKENS_FOLLOWING_T__54_IN_constraint_iterator_1645 = Set[ 41 ] TOKENS_FOLLOWING_T__41_IN_constraint_iterator_1647 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_constraint_iterator_1649 = Set[ 55 ] TOKENS_FOLLOWING_T__55_IN_constraint_iterator_1651 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_constraint_iterator_1653 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_constraint_iterator_1655 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_constraint_iterator_1657 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_constraint_iterator_1660 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_iterator_1662 = Set[ 4, 6, 21, 32, 61, 67 ] TOKENS_FOLLOWING_constraint_statement_IN_constraint_iterator_1672 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_iterator_1680 = Set[ 4, 6, 21, 32, 61, 67 ] TOKENS_FOLLOWING_T__21_IN_constraint_iterator_1687 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_quantification_keyword_0 = Set[ 1 ] TOKENS_FOLLOWING_quantification_keyword_IN_constraint_class_quantification_1723 = Set[ 41 ] TOKENS_FOLLOWING_T__41_IN_constraint_class_quantification_1725 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_constraint_class_quantification_1727 = Set[ 55 ] TOKENS_FOLLOWING_T__55_IN_constraint_class_quantification_1729 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_constraint_class_quantification_1731 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_constraint_class_quantification_1733 = Set[ 4, 20, 59, 81, 82, 83, 84 ] TOKENS_FOLLOWING_binary_comp_IN_constraint_class_quantification_1745 = Set[ 7 ] TOKENS_FOLLOWING_T__59_IN_constraint_class_quantification_1758 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_constraint_class_quantification_1774 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1788 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_constraint_class_quantification_1791 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1793 = Set[ 4, 6, 21, 32, 54, 60, 61, 67 ] TOKENS_FOLLOWING_constraint_statement_IN_constraint_class_quantification_1800 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1810 = Set[ 4, 6, 21, 32, 54, 60, 61, 67 ] TOKENS_FOLLOWING_constraint_different_IN_constraint_class_quantification_1817 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1819 = Set[ 4, 6, 21, 32, 54, 60, 61, 67 ] TOKENS_FOLLOWING_constraint_iterator_IN_constraint_class_quantification_1826 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_constraint_class_quantification_1828 = Set[ 4, 6, 21, 32, 54, 60, 61, 67 ] TOKENS_FOLLOWING_T__21_IN_constraint_class_quantification_1836 = Set[ 1 ] TOKENS_FOLLOWING_T__60_IN_constraint_different_1855 = Set[ 41 ] TOKENS_FOLLOWING_T__41_IN_constraint_different_1857 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_constraint_different_1859 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_constraint_different_1861 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1880 = Set[ 1 ] TOKENS_FOLLOWING_T__61_IN_constraint_statement_1889 = Set[ 6 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1891 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1900 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_constraint_statement_1902 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_constraint_statement_1904 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1913 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_constraint_statement_1915 = Set[ 8 ] TOKENS_FOLLOWING_NULL_IN_constraint_statement_1917 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1926 = Set[ 64, 65, 76 ] TOKENS_FOLLOWING_not_equals_op_IN_constraint_statement_1928 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_constraint_statement_1930 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1939 = Set[ 64, 65, 76 ] TOKENS_FOLLOWING_not_equals_op_IN_constraint_statement_1941 = Set[ 8 ] TOKENS_FOLLOWING_NULL_IN_constraint_statement_1943 = Set[ 1 ] TOKENS_FOLLOWING_conditional_constraint_IN_constraint_statement_1952 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1961 = Set[ 62, 63 ] TOKENS_FOLLOWING_T__62_IN_constraint_statement_1963 = Set[ 63 ] TOKENS_FOLLOWING_T__63_IN_constraint_statement_1966 = Set[ 41 ] TOKENS_FOLLOWING_set_value_IN_constraint_statement_1968 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1977 = Set[ 61, 64, 65 ] TOKENS_FOLLOWING_set_IN_constraint_statement_1979 = Set[ 63 ] TOKENS_FOLLOWING_T__63_IN_constraint_statement_1987 = Set[ 41 ] TOKENS_FOLLOWING_set_value_IN_constraint_statement_1989 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_1998 = Set[ 66 ] TOKENS_FOLLOWING_T__66_IN_constraint_statement_2000 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_constraint_statement_2002 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_constraint_statement_2011 = Set[ 81, 82, 83, 84 ] TOKENS_FOLLOWING_binary_comp_IN_constraint_statement_2013 = Set[ 6, 7 ] TOKENS_FOLLOWING_comp_value_IN_constraint_statement_2015 = Set[ 1 ] TOKENS_FOLLOWING_total_constraint_IN_constraint_statement_2024 = Set[ 1 ] TOKENS_FOLLOWING_T__67_IN_total_constraint_2035 = Set[ 6 ] TOKENS_FOLLOWING_total_statement_IN_total_constraint_2037 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_total_constraint_2039 = Set[ 81, 82, 83, 84 ] TOKENS_FOLLOWING_binary_comp_IN_total_constraint_2041 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_total_constraint_2043 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_total_statement_2054 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_total_statement_2056 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_total_statement_2058 = Set[ 1 ] TOKENS_FOLLOWING_NUMBER_IN_comp_value_2073 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_comp_value_2082 = Set[ 1 ] TOKENS_FOLLOWING_T__32_IN_conditional_constraint_2101 = Set[ 6, 20, 32, 61, 67 ] TOKENS_FOLLOWING_conditional_constraint_if_part_IN_conditional_constraint_2109 = Set[ 33 ] TOKENS_FOLLOWING_conditional_constraint_then_part_IN_conditional_constraint_2113 = Set[ 1 ] TOKENS_FOLLOWING_constraint_statement_IN_conditional_constraint_if_part_2128 = Set[ 1, 4 ] TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2130 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__20_IN_conditional_constraint_if_part_2140 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2148 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_conditional_constraint_if_part_2151 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_conditional_constraint_if_part_2155 = Set[ 1, 4 ] TOKENS_FOLLOWING_NL_IN_conditional_constraint_if_part_2157 = Set[ 1, 4 ] TOKENS_FOLLOWING_T__33_IN_conditional_constraint_then_part_2173 = Set[ 6, 32, 61, 67 ] TOKENS_FOLLOWING_constraint_statement_IN_conditional_constraint_then_part_2175 = Set[ 1 ] TOKENS_FOLLOWING_T__33_IN_conditional_constraint_then_part_2184 = Set[ 20 ] TOKENS_FOLLOWING_T__20_IN_conditional_constraint_then_part_2192 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_conditional_constraint_then_part_2194 = Set[ 4, 6, 21, 32, 54, 56, 57, 58, 61, 67 ] TOKENS_FOLLOWING_constraint_body_IN_conditional_constraint_then_part_2197 = Set[ 21 ] TOKENS_FOLLOWING_T__21_IN_conditional_constraint_then_part_2199 = Set[ 1 ] TOKENS_FOLLOWING_mutation_IN_effect_body_2221 = Set[ 4 ] TOKENS_FOLLOWING_mutation_iterator_IN_effect_body_2234 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_effect_body_2243 = Set[ 1, 4, 6, 54, 69 ] TOKENS_FOLLOWING_T__54_IN_mutation_iterator_2258 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_mutation_iterator_2260 = Set[ 55 ] TOKENS_FOLLOWING_T__55_IN_mutation_iterator_2262 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_mutation_iterator_2264 = Set[ 4, 20 ] TOKENS_FOLLOWING_NL_IN_mutation_iterator_2266 = Set[ 4, 20 ] TOKENS_FOLLOWING_T__20_IN_mutation_iterator_2269 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_mutation_iterator_2271 = Set[ 4, 6, 21, 69 ] TOKENS_FOLLOWING_mutation_IN_mutation_iterator_2281 = Set[ 4 ] TOKENS_FOLLOWING_NL_IN_mutation_iterator_2289 = Set[ 4, 6, 21, 69 ] TOKENS_FOLLOWING_T__21_IN_mutation_iterator_2296 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2315 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_mutation_2317 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_mutation_2319 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2328 = Set[ 59, 62 ] TOKENS_FOLLOWING_equals_op_IN_mutation_2330 = Set[ 8 ] TOKENS_FOLLOWING_NULL_IN_mutation_2332 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2341 = Set[ 77, 78, 79, 80 ] TOKENS_FOLLOWING_binary_op_IN_mutation_2343 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_mutation_2345 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2354 = Set[ 62 ] TOKENS_FOLLOWING_T__62_IN_mutation_2356 = Set[ 68 ] TOKENS_FOLLOWING_T__68_IN_mutation_2358 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_mutation_2360 = Set[ 1, 20 ] TOKENS_FOLLOWING_object_body_IN_mutation_2368 = Set[ 1 ] TOKENS_FOLLOWING_T__69_IN_mutation_2378 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_mutation_2380 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2389 = Set[ 70 ] TOKENS_FOLLOWING_T__70_IN_mutation_2391 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_mutation_2393 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_mutation_2395 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_mutation_2404 = Set[ 71 ] TOKENS_FOLLOWING_T__71_IN_mutation_2406 = Set[ 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_value_IN_mutation_2408 = Set[ 42 ] TOKENS_FOLLOWING_T__42_IN_mutation_2410 = Set[ 1 ] TOKENS_FOLLOWING_T__41_IN_set_value_2429 = Set[ 5, 6, 7, 9, 10, 41, 42, 72 ] TOKENS_FOLLOWING_set_item_IN_set_value_2438 = Set[ 30, 42 ] TOKENS_FOLLOWING_T__30_IN_set_value_2441 = Set[ 4, 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_NL_IN_set_value_2443 = Set[ 4, 5, 6, 7, 9, 10, 41, 72 ] TOKENS_FOLLOWING_set_item_IN_set_value_2446 = Set[ 30, 42 ] TOKENS_FOLLOWING_T__42_IN_set_value_2458 = Set[ 1 ] TOKENS_FOLLOWING_value_IN_set_item_2469 = Set[ 1 ] TOKENS_FOLLOWING_primitive_value_IN_value_2488 = Set[ 1 ] TOKENS_FOLLOWING_reference_IN_value_2497 = Set[ 1 ] TOKENS_FOLLOWING_set_value_IN_value_2506 = Set[ 1 ] TOKENS_FOLLOWING_T__72_IN_value_2515 = Set[ 1 ] TOKENS_FOLLOWING_BOOLEAN_IN_primitive_value_2534 = Set[ 1 ] TOKENS_FOLLOWING_NUMBER_IN_primitive_value_2543 = Set[ 1 ] TOKENS_FOLLOWING_STRING_IN_primitive_value_2552 = Set[ 1 ] TOKENS_FOLLOWING_MULTILINE_STRING_IN_primitive_value_2561 = Set[ 1 ] TOKENS_FOLLOWING_ID_IN_path_2576 = Set[ 1, 73 ] TOKENS_FOLLOWING_T__73_IN_path_2578 = Set[ 6 ] TOKENS_FOLLOWING_ID_IN_path_2579 = Set[ 1, 73 ] TOKENS_FOLLOWING_id_ref_IN_path_with_index_2592 = Set[ 1, 73 ] TOKENS_FOLLOWING_T__73_IN_path_with_index_2594 = Set[ 6 ] TOKENS_FOLLOWING_id_ref_IN_path_with_index_2595 = Set[ 1, 73 ] TOKENS_FOLLOWING_ID_IN_id_ref_2608 = Set[ 1, 28 ] TOKENS_FOLLOWING_T__28_IN_id_ref_2610 = Set[ 7 ] TOKENS_FOLLOWING_NUMBER_IN_id_ref_2612 = Set[ 29 ] TOKENS_FOLLOWING_T__29_IN_id_ref_2614 = Set[ 1 ] TOKENS_FOLLOWING_path_with_index_IN_reference_2631 = Set[ 1 ] TOKENS_FOLLOWING_T__74_IN_reference_type_2650 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_reference_type_2652 = Set[ 1 ] TOKENS_FOLLOWING_T__44_IN_set_type_2671 = Set[ 6 ] TOKENS_FOLLOWING_path_IN_set_type_2673 = Set[ 1 ] TOKENS_FOLLOWING_T__75_IN_probability_op_2688 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_equals_op_0 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_not_equals_op_0 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_binary_op_0 = Set[ 1 ] TOKENS_FOLLOWING_set_IN_binary_comp_0 = Set[ 1 ] end # class Parser < ANTLR3::Parser at_exit { Parser.main( ARGV ) } if __FILE__ == $0 end