(tp treeprinter.Node, expr Expression, includeSpansToRead, redactable bool)
| 420 | } |
| 421 | |
| 422 | func formatExpression(tp treeprinter.Node, expr Expression, includeSpansToRead, redactable bool) { |
| 423 | switch e := expr.(type) { |
| 424 | case *SpanExpression: |
| 425 | n := tp.Child("span expression") |
| 426 | e.Format(n, includeSpansToRead, redactable) |
| 427 | default: |
| 428 | tp.Child(fmt.Sprintf("%v", e)) |
| 429 | } |
| 430 | } |
| 431 | |
| 432 | // ToProto constructs a SpanExpressionProto for execution. It should |
| 433 | // be called on an expression tree that contains only *SpanExpressions. |