[refactoring] update ast structure of "Class" and "Trait" nodes

This commit is contained in:
Vadym Slizov
2020-11-22 02:03:39 +02:00
parent 3bda40e8ce
commit fe2e097d8f
7 changed files with 1257 additions and 1233 deletions

View File

@@ -1476,7 +1476,7 @@ func (p *PrettyPrinter) printStmtClass(n ast.Vertex) {
if nn.ArgumentList != nil {
io.WriteString(p.w, "(")
p.joinPrint(", ", nn.ArgumentList.Arguments)
p.joinPrint(", ", nn.ArgumentList.(*ast.ArgumentList).Arguments)
io.WriteString(p.w, ")")
}

View File

@@ -2097,7 +2097,7 @@ func (p *Printer) printStmtClass(n ast.Vertex) {
if nn.ArgumentList != nil {
p.printFreeFloatingOrDefault(nn.ArgumentList, token.Start, "(")
p.joinPrint(",", nn.ArgumentList.Arguments)
p.joinPrint(",", nn.ArgumentList.(*ast.ArgumentList).Arguments)
p.printFreeFloatingOrDefault(nn.ArgumentList, token.End, ")")
}