123456789_123456789_123456789_123456789_123456789_

Class: TypeProf::Context

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Instance Chain:
Inherits: Object
Defined in: lib/typeprof/analyzer.rb

Class Method Summary

Instance Attribute Summary

Instance Method Summary

Constructor Details

.new(iseq, cref, mid) ⇒ Context

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 30

def initialize(iseq, cref, mid)
  @iseq = iseq
  @cref = cref
  @mid = mid
end

Instance Attribute Details

#cref (readonly)

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 36

attr_reader :iseq, :cref, :mid

#iseq (readonly)

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 36

attr_reader :iseq, :cref, :mid

#mid (readonly)

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 36

attr_reader :iseq, :cref, :mid

Instance Method Details

#replace_cref(cref)

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 46

def replace_cref(cref)
  Context.new(@iseq, cref, @mid)
end

#source_location(pc)

[ GitHub ]

  
# File 'lib/typeprof/analyzer.rb', line 38

def source_location(pc)
  if @iseq
    @iseq.source_location(pc)
  else
    "<builtin>"
  end
end