Class: Steep::Diagnostic::Ruby::UnexpectedPositionalArgument

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

Instance Attribute Summary collapse

Attributes inherited from Base

#location

Instance Method Summary collapse

Methods inherited from Base

#detail_lines, #diagnostic_code

Methods included from Helper

#error_name, #full_message

Constructor Details

#initialize(node:, params:) ⇒ UnexpectedPositionalArgument

Returns a new instance of UnexpectedPositionalArgument.



97
98
99
100
# File 'lib/steep/diagnostic/ruby.rb', line 97

def initialize(node:, params:)
  super(node: node)
  @params = params
end

Instance Attribute Details

#nodeObject (readonly)

Returns the value of attribute node.



94
95
96
# File 'lib/steep/diagnostic/ruby.rb', line 94

def node
  @node
end

#paramsObject (readonly)

Returns the value of attribute params.



95
96
97
# File 'lib/steep/diagnostic/ruby.rb', line 95

def params
  @params
end

Instance Method Details

#header_lineObject



102
103
104
# File 'lib/steep/diagnostic/ruby.rb', line 102

def header_line
  "Unexpected positional argument"
end