| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 class Unparser implements Visitor { | 5 class Unparser implements Visitor { |
| 6 StringBuffer sb; | 6 StringBuffer sb; |
| 7 final bool printDebugInfo; | 7 final bool printDebugInfo; |
| 8 | 8 |
| 9 Unparser([this.printDebugInfo = false]); | 9 Unparser([this.printDebugInfo = false]); |
| 10 | 10 |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 } | 112 } |
| 113 | 113 |
| 114 visitLiteralInt(LiteralInt node) { | 114 visitLiteralInt(LiteralInt node) { |
| 115 add(node.token.value); | 115 add(node.token.value); |
| 116 } | 116 } |
| 117 | 117 |
| 118 visitLiteralString(LiteralString node) { | 118 visitLiteralString(LiteralString node) { |
| 119 add(node.token.value); | 119 add(node.token.value); |
| 120 } | 120 } |
| 121 | 121 |
| 122 visitStringJuxtaposition(LiteralStringJuxtaposition node) { | 122 visitStringJuxtaposition(StringJuxtaposition node) { |
| 123 visit(node.first); | 123 visit(node.first); |
| 124 sb.add(" "); | 124 sb.add(" "); |
| 125 visit(node.second); | 125 visit(node.second); |
| 126 } | 126 } |
| 127 | 127 |
| 128 visitLiteralNull(LiteralNull node) { | 128 visitLiteralNull(LiteralNull node) { |
| 129 add(node.token.value); | 129 add(node.token.value); |
| 130 } | 130 } |
| 131 | 131 |
| 132 visitNewExpression(NewExpression node) { | 132 visitNewExpression(NewExpression node) { |
| (...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 393 sb.add(' '); | 393 sb.add(' '); |
| 394 } | 394 } |
| 395 visit(node.name); | 395 visit(node.name); |
| 396 if (node.typeParameters !== null) { | 396 if (node.typeParameters !== null) { |
| 397 visit(node.typeParameters); | 397 visit(node.typeParameters); |
| 398 } | 398 } |
| 399 visit(node.formals); | 399 visit(node.formals); |
| 400 add(node.endToken.value); | 400 add(node.endToken.value); |
| 401 } | 401 } |
| 402 } | 402 } |
| OLD | NEW |