d6bdd08002
the typechecker project can collect all the top level types from a file, which is pretty cool I think (except for pointers, those aren't implemented yet...)
25 lines
499 B
C#
25 lines
499 B
C#
namespace meowlang.typechecker;
|
|
|
|
public record ArrayTypeDescription : TypeDescription
|
|
{
|
|
private readonly TypeId _elementType;
|
|
private readonly uint _size;
|
|
|
|
public ArrayTypeDescription(TypeId elementType, uint size)
|
|
{
|
|
_elementType = elementType;
|
|
_size = size;
|
|
}
|
|
|
|
public TypeId ElementType => _elementType;
|
|
|
|
public uint Size => _size;
|
|
}
|
|
public record PrimitiveTypeDescription : TypeDescription
|
|
{
|
|
|
|
public PrimitiveTypeDescription()
|
|
{
|
|
|
|
}
|
|
} |