Rewrote type section correct test

This commit is contained in:
Sasha Koshka 2022-09-28 10:36:29 -04:00
parent f4c079786b
commit 1bd886fea0

View File

@ -6,55 +6,42 @@ func TestType (test *testing.T) {
checkTree ("../tests/parser/type", false, checkTree ("../tests/parser/type", false,
`:arf `:arf
--- ---
type ro aBasic:Obj: type ro aBasic:Obj
( ro that:Int
.ro that:Int ro this:Int
.ro this:Int
) type ro bBitFields:Obj
type ro bBitFields:Obj: ro that:Int & 1
( ro this:Int
.ro that:Int & 1 298 & 24
.ro this:Int:<298> & 24 type ro cInit:Obj
) ro that:String
type ro cInit:Obj: "hello world"
( ro this:Int
.ro that:String:<"hello world"> 23
.ro this:Int:<23> type ro dInitInherit:aBasic
) ro that
type ro dInitInherit:aBasic: 9384
( ro this
.that:<9384> 389
.this:<389> type ro eInitAndDefine:aBasic
) ro this
type ro eInitAndDefine:aBasic: 389
( ro that
.ro these:aBasic: 9384
( ro born:Int
.ro born:Int:<4> 4
.ro in:Int ro in:Int
.ro the:Int:3: ro the:Int:3
< (9348 92384 92834)
9348 ro walls:String
92384 "live in the walls, die in the walls."
92834
>
):
(
.this:<98>
)
):
(
.that:<9384>
.this:<389>
)
type ro fBasic:Int type ro fBasic:Int
type ro gBasicInit:Int:<6> type ro gBasicInit:Int
6
type ro hIntArray:{Int ..} type ro hIntArray:{Int ..}
type ro iIntArrayInit:Int:3: type ro iIntArrayInit:Int:3
< (3298 923 92)
3298
923
92
>
`, test) `, test)
} }