Class: Steep::Diagnostic::Ruby::UnknownRecordKey

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

Instance Attribute Summary collapse

Attributes inherited from Base

#location, #node

Instance Method Summary collapse

Methods inherited from Base

#detail_lines, #diagnostic_code

Methods included from Helper

#error_name, #full_message

Constructor Details

#initialize(key:, node:) ⇒ UnknownRecordKey

Returns a new instance of UnknownRecordKey.



1007
1008
1009
1010
# File 'lib/steep/diagnostic/ruby.rb', line 1007

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

Instance Attribute Details

#keyObject (readonly)

Returns the value of attribute key.



1005
1006
1007
# File 'lib/steep/diagnostic/ruby.rb', line 1005

def key
  @key
end

Instance Method Details

#header_lineObject



1012
1013
1014
# File 'lib/steep/diagnostic/ruby.rb', line 1012

def header_line
  "Unknown key `#{key.inspect}` is given to a record type"
end