Class: Ripper::SexpBuilderPP
| Relationships & Source Files | |
| Super Chains via Extension / Inclusion / Inheritance | |
| Class Chain: 
          self,
          SexpBuilder,
          ::Ripper
         | |
| Instance Chain: 
          self,
          SexpBuilder,
          ::Ripper
         | |
| Inherits: | Ripper::SexpBuilder 
 | 
| Defined in: | ext/ripper/lib/ripper/sexp.rb | 
Constant Summary
::Ripper - Inherited
Class Method Summary
::Ripper - Inherited
| .dedent_string, | |
| .lex | Tokenizes the Ruby program and returns an array of an array, which is formatted like  | 
| .lex_state_name, | |
| .new | Create a new ::Ripper object. | 
| .parse | Parses the given Ruby program read from  | 
| .sexp | 
 | 
| .sexp_raw | 
 | 
| .slice | 
 | 
| .tokenize | Tokenizes the Ruby program and returns an array of strings. | 
| .token_match | |
Instance Attribute Summary
::Ripper - Inherited
| #end_seen? | Return true if parsed source ended by _END_. | 
| #error? | Return true if parsed source has errors. | 
| #yydebug | Get yydebug. | 
| #yydebug= | Set yydebug. | 
Instance Method Summary
- #_dispatch_event_new private
- #_dispatch_event_push(list, item) private
- #on_heredoc_dedent(val, width) private
- #on_mlhs_add_post(list, post) private
- #on_mlhs_add_star(list, star) private
- #on_mlhs_paren(list) private
SexpBuilder - Inherited
::Ripper - Inherited
| #column | Return column number of current parsing line. | 
| #encoding | Return encoding of the source. | 
| #filename | Return current parsing filename. | 
| #lineno | Return line number of current parsing line. | 
| #parse | Start parsing and returns the value of the root action. | 
| #state | Return scanner state of current token. | 
| #_dispatch_0, #_dispatch_1, #_dispatch_2, #_dispatch_3, #_dispatch_4, #_dispatch_5, #_dispatch_6, #_dispatch_7, | |
| #compile_error | This method is called when the parser found syntax error. | 
| #dedent_string | Alias for dedent_string. | 
| #warn | This method is called when weak warning is produced by the parser. | 
| #warning | This method is called when strong warning is produced by the parser. | 
Constructor Details
This class inherits a constructor from Ripper
Instance Method Details
#_dispatch_event_new (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 128
def _dispatch_event_new [] end
#_dispatch_event_push(list, item) (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 132
def _dispatch_event_push(list, item) list.push item list end
#on_heredoc_dedent(val, width) (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 115
def on_heredoc_dedent(val, width) val.map! do |e| next e if Symbol === e and /_content\z/ =~ e if Array === e and e[0] == :@tstring_content e = dedent_element(e, width) elsif String === e dedent_string(e, width) end e end val end
#on_mlhs_add_post(list, post) (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 145
def on_mlhs_add_post(list, post) list.concat(post) end
#on_mlhs_add_star(list, star) (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 141
def on_mlhs_add_star(list, star) list.push([:rest_param, star]) end
#on_mlhs_paren(list) (private)
[ GitHub ]# File 'ext/ripper/lib/ripper/sexp.rb', line 137
def on_mlhs_paren(list) [:mlhs, *list] end