Class: CodeTools::AST::DynamicRegex
  
  
  
  Instance Attribute Summary
  
  
  #array, #options
  
  
  
  #string
  
  
  Attributes inherited from Node
  #line
  
    
      Instance Method Summary
      collapse
    
    
  
  
  
  
  
  
  
  
  
  
  #defined
  
  
  
  
  
  
  
  
  
  #defined
  
  
  
  
  
  
  
  
  Methods inherited from Node
  #ascii_graph, #attributes, #children, #defined, match_arguments?, match_send?, #new_block_generator, #new_generator, #node_name, #or_bytecode, #pos, #set_child, #transform, transform, transform_comment, transform_kind, transform_kind=, transform_name, #value_defined, #visit, #walk
  Constructor Details
  
    
  
  
    #initialize(line, str, array, flags)  ⇒ DynamicRegex 
  
  
  
  
    
Returns a new instance of DynamicRegex.
   
 
  
  
    | 
545
546
547
548 | # File 'lib/rubinius/code/ast/literals.rb', line 545
def initialize(line, str, array, flags)
  super line, str, array
  @options = flags || 0
end | 
 
  
 
  
    Instance Method Details
    
      
  
  
    #bytecode(g)  ⇒ Object 
  
  
  
  
    | 
550
551
552
553
554
555
556 | # File 'lib/rubinius/code/ast/literals.rb', line 550
def bytecode(g)
  g.push_cpath_top
  g.find_const :Regexp
  super(g)
  g.push_int @options
  g.send :new, 2
end | 
 
    
      
  
  
    #sexp_name  ⇒ Object 
  
  
  
  
    | 
558
559
560 | # File 'lib/rubinius/code/ast/literals.rb', line 558
def sexp_name
  :dregx
end | 
 
    
      
  
  
    #to_sexp  ⇒ Object 
  
  
  
  
    | 
562
563
564
565
566 | # File 'lib/rubinius/code/ast/literals.rb', line 562
def to_sexp
  sexp = super
  sexp << @options if @options != 0
  sexp
end |