Class: TRuby::IR::InterpolatedString

Inherits:
Node
  • Object
show all
Defined in:
lib/t_ruby/ir.rb

Overview

Interpolated string (string with #… expressions)

Instance Attribute Summary collapse

Attributes inherited from Node

#location, #metadata, #type_info

Instance Method Summary collapse

Methods inherited from Node

#accept, #transform

Constructor Details

#initialize(parts: [], **opts) ⇒ InterpolatedString

Returns a new instance of InterpolatedString.



241
242
243
244
# File 'lib/t_ruby/ir.rb', line 241

def initialize(parts: [], **opts)
  super(**opts)
  @parts = parts
end

Instance Attribute Details

#partsObject

Returns the value of attribute parts.



239
240
241
# File 'lib/t_ruby/ir.rb', line 239

def parts
  @parts
end

Instance Method Details

#childrenObject



246
247
248
# File 'lib/t_ruby/ir.rb', line 246

def children
  @parts
end