class TypeProf::Core::Type::Instance
Attributes
Public Class Methods
Source
# File bundled-src/typeprof-0.31.1/lib/typeprof/core/type.rb, line 69 def initialize(genv, mod, args) raise mod.class.to_s unless mod.is_a?(ModuleEntity) @mod = mod @args = args raise unless @args.is_a?(::Array) end
: (GlobalEnv, ModuleEntity, ::Array[Vertex]) -> void
Public Instance Methods
Source
# File bundled-src/typeprof-0.31.1/lib/typeprof/core/type.rb, line 78 def base_type(_) self end
Source
# File bundled-src/typeprof-0.31.1/lib/typeprof/core/type.rb, line 82 def show case @mod.cpath when [:NilClass] then "nil" when [:TrueClass] then "true" when [:FalseClass] then "false" else "#{ @mod.show_cpath }#{ @args.empty? ? "" : "[#{ @args.map {|arg| Type.strip_parens(arg.show) }.join(", ") }]" }" end end