class School::Lit

Overview

A literal.

Included Modules

Defined in:

school/rule/expression.cr

Constructors

Instance Method Summary

Macro Summary

Instance methods inherited from module School::Matcher

match(value : DomainTypes) : Result match

Instance methods inherited from class School::Expression

name name, name? : String? name?

Constructor Detail

def self.new(target : DomainTypes, name : String | Nil = nil) #

[View source]

Instance Method Detail

def ==(other : self) #

Returns true if this reference is the same as other. Invokes same?.


[View source]
def match(value : DomainTypes) : Result #

Matches the expression to a value.


[View source]
def target : Bool | Char | Float32 | Float64 | Int32 | Int64 | School::DomainType | String | Symbol | Nil #

[View source]

Macro Detail

macro method_missing(call) #

Generates an accessor that performs the method call on the literal value.


[View source]