class SFRP::Poly::TypeAnnotationType
Public Class Methods
new(tconst_str, arg_type_annots)
click to toggle source
# File lib/sfrp/poly/typing.rb, line 159 def initialize(tconst_str, arg_type_annots) @tconst_str = tconst_str @arg_type_annots = arg_type_annots end
Public Instance Methods
to_s()
click to toggle source
# File lib/sfrp/poly/typing.rb, line 172 def to_s return @tconst_str if @arg_type_annots.empty? "#{@tconst_str}[#{@arg_type_annots.map(&:to_s).join(', ')}]" end
to_typing(tbl)
click to toggle source
# File lib/sfrp/poly/typing.rb, line 164 def to_typing(tbl) Typing.new(@tconst_str, @arg_type_annots.map { |ta| ta.to_typing(tbl) }) end
var_strs()
click to toggle source
# File lib/sfrp/poly/typing.rb, line 168 def var_strs @arg_type_annots.flat_map(&:var_strs) end