(n node.Node)
| 454 | } |
| 455 | |
| 456 | func (p *Printer) printNodeParameter(n node.Node) { |
| 457 | nn := n.(*node.Parameter) |
| 458 | p.printFreeFloating(nn, freefloating.Start) |
| 459 | |
| 460 | if nn.VariableType != nil { |
| 461 | p.Print(nn.VariableType) |
| 462 | } |
| 463 | p.printFreeFloating(nn, freefloating.OptionalType) |
| 464 | |
| 465 | if nn.ByRef { |
| 466 | io.WriteString(p.w, "&") |
| 467 | } |
| 468 | p.printFreeFloating(nn, freefloating.Ampersand) |
| 469 | |
| 470 | if nn.Variadic { |
| 471 | io.WriteString(p.w, "...") |
| 472 | } |
| 473 | p.printFreeFloating(nn, freefloating.Variadic) |
| 474 | |
| 475 | p.Print(nn.Variable) |
| 476 | |
| 477 | if nn.DefaultValue != nil { |
| 478 | p.printFreeFloating(nn, freefloating.Var) |
| 479 | io.WriteString(p.w, "=") |
| 480 | p.Print(nn.DefaultValue) |
| 481 | } |
| 482 | |
| 483 | p.printFreeFloating(nn, freefloating.End) |
| 484 | } |
| 485 | |
| 486 | func (p *Printer) printNodeNullable(n node.Node) { |
| 487 | nn := n.(*node.Nullable) |
no test coverage detected