Class Ruva::VM::Types::Cat2Value
In: lib/ruva/types.rb
Parent: Object

a category two type on the stack. Only needed so we know whether to pop one or two…

Methods

External Aliases

new -> []

Attributes

__value  [RW] 

Public Class methods

[Source]

    # File lib/ruva/types.rb, line 25
25:         def initialize(value)
26:           @__value = value;
27:         end

Public Instance methods

[Source]

    # File lib/ruva/types.rb, line 42
42:         def inspect
43:           "#<Cat2:#{@__value.inspect}>"
44:         end

special case this to let us check for c2type

[Source]

    # File lib/ruva/types.rb, line 34
34:         def is_a?(clz)
35:           clz == Cat2Value || @__value.is_a?(clz)          
36:         end

[Source]

    # File lib/ruva/types.rb, line 46
46:         def method_missing(sym, *args)
47:           @__value.send(sym,*args)
48:         end

[Source]

    # File lib/ruva/types.rb, line 38
38:         def respond_to?(sym)
39:           sym.to_s == '__value' || @__value.respond_to?(sym)
40:         end

[Validate]