Add non-basic types to type section test case

This commit is contained in:
Sasha Koshka 2022-10-18 15:00:42 -04:00
parent 2a1a48d9c5
commit ae0765b8f4
3 changed files with 9 additions and 1 deletions

View File

@ -37,5 +37,9 @@ typeSection ro ../tests/analyzer/typeSection.fInheritObjectFromOther
member ro beak
type 1 basic Int
arg uint 238
typeSection ro ../tests/analyzer/typeSection.gPointer
type 1 pointer {Int}
typeSection ro ../tests/analyzer/typeSection.hDynamicArray
type 1 dynamicArray {Int}
`, test)
}

View File

@ -53,7 +53,7 @@ func (what Type) ToString (indent int) (output string) {
case TypeKindPointer:
output += " pointer"
case TypeKindVariableArray:
output += " variableArray"
output += " dynamicArray"
}
if what.points != nil {

View File

@ -19,4 +19,8 @@ type ro fInheritObjectFromOther:required.bBird
ro wing 2
ro beak:Int 238
type ro gPointer:{Int}
type ro hDynamicArray:{Int ..}
# TODO: test a type that has a member pointing to itself