Class: T::Private::Types::Void

Inherits:
Types::Base show all
Defined in:
lib/types/private/types/void.rb

Defined Under Namespace

Modules: Private, VOID

Constant Summary collapse

ERROR_MESSAGE =
"Validation is being done on an `Void`. Please report this bug at https://github.com/sorbet/sorbet/issues"

Instance Method Summary collapse

Methods inherited from Types::Base

#==, #describe_obj, #error_message_for_obj, #error_message_for_obj_recursive, #hash, method_added, #recursively_valid?, #subtype_of?, #to_s, #validate!

Instance Method Details

#build_typeObject



21
22
23
# File 'lib/types/private/types/void.rb', line 21

def build_type
  nil
end

#nameObject

overrides Base



26
27
28
# File 'lib/types/private/types/void.rb', line 26

def name
  "<VOID>"
end

#valid?(obj) ⇒ Boolean

overrides Base

Returns:

Raises:



31
32
33
# File 'lib/types/private/types/void.rb', line 31

def valid?(obj)
  raise ERROR_MESSAGE
end