Class: Jade::Frontend::SemanticAnalysis::Error::MissingExtendsImplementation

Inherits:
Error
  • Object
show all
Defined in:
lib/jade/frontend/semantic_analysis/error/missing_extends_implementation.rb

Instance Attribute Summary

Attributes inherited from Error

#entry, #span

Instance Method Summary collapse

Methods inherited from Error

#candidates, #label, #notes, #queried_name, #to_diagnostic

Constructor Details

#initialize(entry, span, interface:, type:, required_by:) ⇒ MissingExtendsImplementation

Returns a new instance of MissingExtendsImplementation.



6
7
8
9
10
11
# File 'lib/jade/frontend/semantic_analysis/error/missing_extends_implementation.rb', line 6

def initialize(entry, span, interface:, type:, required_by:)
  super(entry:, span:)
  @interface   = interface
  @type        = type
  @required_by = required_by
end

Instance Method Details

#messageObject



13
14
15
16
# File 'lib/jade/frontend/semantic_analysis/error/missing_extends_implementation.rb', line 13

def message
  "implements #{@required_by} extends #{@interface}: " \
    "#{@interface} is not implemented for #{@type}"
end