Class: Steep::Errors::UnresolvedOverloading

Inherits:
Base
  • Object
show all
Defined in:
lib/steep/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#location_to_str, #print_to

Constructor Details

#initialize(node:, receiver_type:, method_name:, method_types:) ⇒ UnresolvedOverloading

Returns a new instance of UnresolvedOverloading.



74
75
76
77
78
79
# File 'lib/steep/errors.rb', line 74

def initialize(node:, receiver_type:, method_name:, method_types:)
  super node: node
  @receiver_type = receiver_type
  @method_name = method_name
  @method_types = method_types
end

Instance Attribute Details

#method_nameObject (readonly)

Returns the value of attribute method_name.



71
72
73
# File 'lib/steep/errors.rb', line 71

def method_name
  @method_name
end

#method_typesObject (readonly)

Returns the value of attribute method_types.



72
73
74
# File 'lib/steep/errors.rb', line 72

def method_types
  @method_types
end

#nodeObject (readonly)

Returns the value of attribute node.



69
70
71
# File 'lib/steep/errors.rb', line 69

def node
  @node
end

#receiver_typeObject (readonly)

Returns the value of attribute receiver_type.



70
71
72
# File 'lib/steep/errors.rb', line 70

def receiver_type
  @receiver_type
end

Instance Method Details

#to_sObject



81
82
83
# File 'lib/steep/errors.rb', line 81

def to_s
  "#{location_to_str}: UnresolvedOverloading: receiver=#{receiver_type}, method_name=#{method_name}, method_types=#{method_types.join(" | ")}"
end