Class: Jade::Frontend::SemanticAnalysis::Error::CircularExtends

Inherits:
Error
  • Object
show all
Defined in:
lib/jade/frontend/semantic_analysis/error/circular_extends.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:) ⇒ CircularExtends

Returns a new instance of CircularExtends.



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

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

Instance Method Details

#messageObject



12
13
14
# File 'lib/jade/frontend/semantic_analysis/error/circular_extends.rb', line 12

def message
  "circular extends detected: #{@interface} for #{@type} is part of a cycle"
end