class Mint::TypeChecker::Record
- Mint::TypeChecker::Record
- Reference
- Object
Defined in:
type_checker/record.crConstructors
Instance Method Summary
- #==(other : Hash(String, Checkable))
- #==(other : Record)
- #fields : Hash(String, Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable)
- #have_holes?
- #label : String | Nil
- #label=(label : String | Nil)
- #mappings : Hash(String, String?)
- #name : String
- #parameters : Array(Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable)
- #parameters=(parameters : Array(Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable))
- #to_mint
- #to_pretty
-
#to_s(io : IO)
Appends a short String representation of this object which includes its class name and its object address.
Constructor Detail
def self.new(name : String, fields : Hash(String, Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable) = {} of String => Checkable, mappings : Hash(String, Nil | String) = {} of String => String | ::Nil, label : Nil | String = nil)
#
Instance Method Detail
def fields : Hash(String, Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable)
#
def parameters : Array(Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable)
#
def parameters=(parameters : Array(Mint::TypeChecker::Record | Mint::TypeChecker::Type | Mint::TypeChecker::Variable))
#
def to_s(io : IO)
#
Description copied from class Reference
Appends a short String representation of this object which includes its class name and its object address.
class Person
def initialize(@name : String, @age : Int32)
end
end
Person.new("John", 32).to_s # => #<Person:0x10a199f20>