Class: Rigor::Type::Bot
- Inherits:
-
Object
- Object
- Rigor::Type::Bot
- Defined in:
- lib/rigor/type/bot.rb
Overview
The bottom of the value lattice: contains no values. The result type of expressions that cannot terminate normally. See docs/type-specification/special-types.md.
Class Method Summary collapse
Instance Method Summary collapse
- #==(other) ⇒ Object (also: #eql?)
- #accepts(other, mode: :gradual) ⇒ Object
- #bot ⇒ Object
- #describe(_verbosity = :short) ⇒ Object
- #dynamic ⇒ Object
- #erase_to_rbs ⇒ Object
- #hash ⇒ Object
- #inspect ⇒ Object
- #top ⇒ Object
Class Method Details
.instance ⇒ Object
12 13 14 |
# File 'lib/rigor/type/bot.rb', line 12 def instance @instance ||= new.freeze end |
Instance Method Details
#==(other) ⇒ Object Also known as: eql?
43 44 45 |
# File 'lib/rigor/type/bot.rb', line 43 def ==(other) other.is_a?(Bot) end |
#accepts(other, mode: :gradual) ⇒ Object
39 40 41 |
# File 'lib/rigor/type/bot.rb', line 39 def accepts(other, mode: :gradual) Inference::Acceptance.accepts(self, other, mode: mode) end |
#describe(_verbosity = :short) ⇒ Object
19 20 21 |
# File 'lib/rigor/type/bot.rb', line 19 def describe(_verbosity = :short) "bot" end |
#erase_to_rbs ⇒ Object
23 24 25 |
# File 'lib/rigor/type/bot.rb', line 23 def erase_to_rbs "bot" end |
#hash ⇒ Object
48 49 50 |
# File 'lib/rigor/type/bot.rb', line 48 def hash Bot.hash end |
#inspect ⇒ Object
52 53 54 |
# File 'lib/rigor/type/bot.rb', line 52 def inspect "#<Rigor::Type::Bot>" end |