| 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 part of js_backend; | 5 part of js_backend; |
| 6 | 6 |
| 7 class JavaScriptItemCompilationContext extends ItemCompilationContext { | 7 class JavaScriptItemCompilationContext extends ItemCompilationContext { |
| 8 final Set<HInstruction> boundsChecked; | 8 final Set<HInstruction> boundsChecked; |
| 9 | 9 |
| 10 JavaScriptItemCompilationContext() | 10 JavaScriptItemCompilationContext() |
| (...skipping 1559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1570 } else if (element == preserveNamesMarker) { | 1570 } else if (element == preserveNamesMarker) { |
| 1571 mustPreserveNames = true; | 1571 mustPreserveNames = true; |
| 1572 } else if (element == preserveMetadataMarker) { | 1572 } else if (element == preserveMetadataMarker) { |
| 1573 mustRetainMetadata = true; | 1573 mustRetainMetadata = true; |
| 1574 } | 1574 } |
| 1575 } | 1575 } |
| 1576 | 1576 |
| 1577 /// Called when [:const Symbol(name):] is seen. | 1577 /// Called when [:const Symbol(name):] is seen. |
| 1578 void registerConstSymbol(String name, TreeElements elements) { | 1578 void registerConstSymbol(String name, TreeElements elements) { |
| 1579 symbolsUsed.add(name); | 1579 symbolsUsed.add(name); |
| 1580 if (name.endsWith('=')) { |
| 1581 symbolsUsed.add(name.substring(0, name.length - 1)); |
| 1582 } |
| 1580 } | 1583 } |
| 1581 | 1584 |
| 1582 /// Called when [:new Symbol(...):] is seen. | 1585 /// Called when [:new Symbol(...):] is seen. |
| 1583 void registerNewSymbol(TreeElements elements) { | 1586 void registerNewSymbol(TreeElements elements) { |
| 1584 } | 1587 } |
| 1585 | 1588 |
| 1586 /// Called when resolving the `Symbol` constructor. | 1589 /// Called when resolving the `Symbol` constructor. |
| 1587 void registerSymbolConstructor(TreeElements elements) { | 1590 void registerSymbolConstructor(TreeElements elements) { |
| 1588 // Make sure that collection_dev.Symbol.validated is registered. | 1591 // Make sure that collection_dev.Symbol.validated is registered. |
| 1589 assert(compiler.symbolValidatedConstructor != null); | 1592 assert(compiler.symbolValidatedConstructor != null); |
| (...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1839 copy(constant.values); | 1842 copy(constant.values); |
| 1840 copy(constant.protoValue); | 1843 copy(constant.protoValue); |
| 1841 copy(constant); | 1844 copy(constant); |
| 1842 } | 1845 } |
| 1843 | 1846 |
| 1844 void visitConstructed(ConstructedConstant constant) { | 1847 void visitConstructed(ConstructedConstant constant) { |
| 1845 copy(constant.fields); | 1848 copy(constant.fields); |
| 1846 copy(constant); | 1849 copy(constant); |
| 1847 } | 1850 } |
| 1848 } | 1851 } |
| OLD | NEW |