| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 part of js_backend; | 5 part of js_backend; |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * Assigns JavaScript identifiers to Dart variables, class-names and members. | 8 * Assigns JavaScript identifiers to Dart variables, class-names and members. |
| 9 */ | 9 */ |
| 10 class Namer implements ClosureNamer { | 10 class Namer implements ClosureNamer { |
| (...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 } | 218 } |
| 219 | 219 |
| 220 final String currentIsolate = r'$'; | 220 final String currentIsolate = r'$'; |
| 221 final String getterPrefix = r'get$'; | 221 final String getterPrefix = r'get$'; |
| 222 final String setterPrefix = r'set$'; | 222 final String setterPrefix = r'set$'; |
| 223 final String superPrefix = r'super$'; | 223 final String superPrefix = r'super$'; |
| 224 final String metadataField = '@'; | 224 final String metadataField = '@'; |
| 225 final String callPrefix = 'call'; | 225 final String callPrefix = 'call'; |
| 226 final String callCatchAllName = r'call$catchAll'; | 226 final String callCatchAllName = r'call$catchAll'; |
| 227 final String reflectableField = r'$reflectable'; | 227 final String reflectableField = r'$reflectable'; |
| 228 final String reflectionInfoField = r'$reflectionInfo'; |
| 229 final String reflectionNameField = r'$reflectionName'; |
| 230 final String metadataIndexField = r'$metadataIndex'; |
| 228 final String defaultValuesField = r'$defaultValues'; | 231 final String defaultValuesField = r'$defaultValues'; |
| 229 final String methodsWithOptionalArgumentsField = | 232 final String methodsWithOptionalArgumentsField = |
| 230 r'$methodsWithOptionalArguments'; | 233 r'$methodsWithOptionalArguments'; |
| 231 | 234 |
| 232 final String classDescriptorProperty = r'^'; | 235 final String classDescriptorProperty = r'^'; |
| 233 | 236 |
| 234 // Name of property in a class description for the native dispatch metadata. | 237 // Name of property in a class description for the native dispatch metadata. |
| 235 final String nativeSpecProperty = '%'; | 238 final String nativeSpecProperty = '%'; |
| 236 | 239 |
| 237 static final RegExp IDENTIFIER = new RegExp(r'^[A-Za-z_$][A-Za-z0-9_$]*$'); | 240 static final RegExp IDENTIFIER = new RegExp(r'^[A-Za-z_$][A-Za-z0-9_$]*$'); |
| (...skipping 1175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1413 if (!first) { | 1416 if (!first) { |
| 1414 sb.write('_'); | 1417 sb.write('_'); |
| 1415 } | 1418 } |
| 1416 sb.write('_'); | 1419 sb.write('_'); |
| 1417 visit(parameter); | 1420 visit(parameter); |
| 1418 first = true; | 1421 first = true; |
| 1419 } | 1422 } |
| 1420 } | 1423 } |
| 1421 } | 1424 } |
| 1422 } | 1425 } |
| OLD | NEW |