Fixed TypeMember.ToString

Type section now passes test
This commit is contained in:
Sasha Koshka 2022-09-16 22:54:26 -04:00
parent 2a1e8c5df7
commit f1cd9856ea
2 changed files with 9 additions and 4 deletions

View File

@ -122,7 +122,7 @@ func (member TypeMember) ToString (indent int, breakLine bool) (output string) {
output += member.permission.ToString() + " "
output += member.name + ":"
output += member.what.ToString(indent, breakLine)
output += member.what.ToString(indent + 1, breakLine)
if member.bitWidth > 0 {
output += fmt.Sprint(" & ", member.bitWidth)
@ -427,7 +427,7 @@ func (phrase Phrase) ToString (indent int, ownLine bool) (output string) {
output += "\n"
output += phrase.block.ToString(indent + 1)
} else if len(phrase.block) > 0 {
output += "NON BLOCKLEVEL PHRASE HAS BLOCK"
output += "NON-BLOCK-LEVEL-PHRASE-HAS-BLOCK"
}
return
}

View File

@ -26,13 +26,18 @@ type ro dInitInherit:aBasic:
.that:<9384>
.this:<389>
)
type ro cInitAndDefine:aBasic:
type ro eInitAndDefine:aBasic:
(
.ro these:aBasic:
(
.ro born:Int:<4>
.ro in:Int
.ro the:Int:3:<9348 92384 92834>
.ro the:Int:3:
<
9348
92384
92834
>
):
(
.this:<98>