class Stacklang::Type::Struct

Defined in:

stacklang/compiler/types.cr

Constructors

Instance Method Summary

Instance methods inherited from class Stacklang::Type::Any

size size

Class methods inherited from class Stacklang::Type::Any

solve_constraint(ast : AST::Type, types : Hash(String, Type::Struct), stack : Array(Type::Any) = [] of Type::Any) : Type::Any solve_constraint

Constructor Detail

def self.new(ast : AST::Struct) #

[View source]

Instance Method Detail


[View source]
def fields : Array(Field) #

[View source]
def fields=(fields : Array(Field)) #

[View source]
def name : String #

[View source]
def name=(name : String) #

[View source]
def size : UInt16 #

[View source]
def solve(other_types : Hash(String, Type::Struct), stack : Array(Type::Any) = [] of Type::Any) #

Compute the size and fields of the structures. It needs all other structure types to be given.


[View source]
def to_s(io) #

[View source]