| 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 typedef void Recompile(Element element); | 7 typedef void Recompile(Element element); |
| 8 | 8 |
| 9 class ReturnInfo { | 9 class ReturnInfo { |
| 10 HType returnType; | 10 HType returnType; |
| (...skipping 1082 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1093 } else if (cls == compiler.listClass | 1093 } else if (cls == compiler.listClass |
| 1094 || cls == compiler.stringClass) { | 1094 || cls == compiler.stringClass) { |
| 1095 // The backend will try to optimize array and string access and use the | 1095 // The backend will try to optimize array and string access and use the |
| 1096 // `ioore` and `iae` helpers directly. | 1096 // `ioore` and `iae` helpers directly. |
| 1097 enqueuer.registerStaticUse( | 1097 enqueuer.registerStaticUse( |
| 1098 compiler.findHelper(const SourceString('ioore'))); | 1098 compiler.findHelper(const SourceString('ioore'))); |
| 1099 enqueuer.registerStaticUse( | 1099 enqueuer.registerStaticUse( |
| 1100 compiler.findHelper(const SourceString('iae'))); | 1100 compiler.findHelper(const SourceString('iae'))); |
| 1101 } else if (cls == compiler.functionClass) { | 1101 } else if (cls == compiler.functionClass) { |
| 1102 enqueuer.registerInstantiatedClass(compiler.closureClass, elements); | 1102 enqueuer.registerInstantiatedClass(compiler.closureClass, elements); |
| 1103 enqueuer.registerInstantiatedClass( |
| 1104 compiler.boundClosureClass, elements); |
| 1103 } else if (cls == compiler.mapClass) { | 1105 } else if (cls == compiler.mapClass) { |
| 1104 // The backend will use a literal list to initialize the entries | 1106 // The backend will use a literal list to initialize the entries |
| 1105 // of the map. | 1107 // of the map. |
| 1106 enqueuer.registerInstantiatedClass(compiler.listClass, elements); | 1108 enqueuer.registerInstantiatedClass(compiler.listClass, elements); |
| 1107 enqueuer.registerInstantiatedClass(mapLiteralClass, elements); | 1109 enqueuer.registerInstantiatedClass(mapLiteralClass, elements); |
| 1108 enqueueInResolution(getMapMaker(), elements); | 1110 enqueueInResolution(getMapMaker(), elements); |
| 1109 } | 1111 } |
| 1110 } | 1112 } |
| 1111 ClassElement result = null; | 1113 ClassElement result = null; |
| 1112 if (cls == compiler.stringClass || cls == jsStringClass) { | 1114 if (cls == compiler.stringClass || cls == jsStringClass) { |
| (...skipping 761 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1874 ClassElement get listImplementation => jsArrayClass; | 1876 ClassElement get listImplementation => jsArrayClass; |
| 1875 ClassElement get constListImplementation => jsArrayClass; | 1877 ClassElement get constListImplementation => jsArrayClass; |
| 1876 ClassElement get fixedListImplementation => jsFixedArrayClass; | 1878 ClassElement get fixedListImplementation => jsFixedArrayClass; |
| 1877 ClassElement get growableListImplementation => jsExtendableArrayClass; | 1879 ClassElement get growableListImplementation => jsExtendableArrayClass; |
| 1878 ClassElement get mapImplementation => mapLiteralClass; | 1880 ClassElement get mapImplementation => mapLiteralClass; |
| 1879 ClassElement get constMapImplementation => constMapLiteralClass; | 1881 ClassElement get constMapImplementation => constMapLiteralClass; |
| 1880 ClassElement get typeImplementation => typeLiteralClass; | 1882 ClassElement get typeImplementation => typeLiteralClass; |
| 1881 ClassElement get boolImplementation => jsBoolClass; | 1883 ClassElement get boolImplementation => jsBoolClass; |
| 1882 ClassElement get nullImplementation => jsNullClass; | 1884 ClassElement get nullImplementation => jsNullClass; |
| 1883 } | 1885 } |
| OLD | NEW |