| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 library dart2js.js_emitter.program_builder; | 5 library dart2js.js_emitter.program_builder; |
| 6 | 6 |
| 7 import '../js_emitter.dart' show computeMixinClass; | 7 import '../js_emitter.dart' show computeMixinClass; |
| 8 import '../model.dart'; | 8 import '../model.dart'; |
| 9 | 9 |
| 10 import '../../common.dart'; | 10 import '../../common.dart'; |
| (...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 318 js.Name name = namer.className(element); | 318 js.Name name = namer.className(element); |
| 319 | 319 |
| 320 return new Class( | 320 return new Class( |
| 321 element, name, null, [], instanceFields, [], [], [], [], [], null, | 321 element, name, null, [], instanceFields, [], [], [], [], [], null, |
| 322 isDirectlyInstantiated: true, | 322 isDirectlyInstantiated: true, |
| 323 onlyForRti: false, | 323 onlyForRti: false, |
| 324 isNative: element.isNative); | 324 isNative: element.isNative); |
| 325 } | 325 } |
| 326 | 326 |
| 327 Class _buildClass(ClassElement element) { | 327 Class _buildClass(ClassElement element) { |
| 328 bool onlyForRti = _task.typeTestRegistry.rtiNeededClasses.contains(element); | 328 bool onlyForRti = _task.classesOnlyNeededForRti.contains(element); |
| 329 | 329 |
| 330 List<Method> methods = []; | 330 List<Method> methods = []; |
| 331 List<StubMethod> callStubs = <StubMethod>[]; | 331 List<StubMethod> callStubs = <StubMethod>[]; |
| 332 | 332 |
| 333 ClassStubGenerator classStubGenerator = | 333 ClassStubGenerator classStubGenerator = |
| 334 new ClassStubGenerator(_compiler, namer, backend); | 334 new ClassStubGenerator(_compiler, namer, backend); |
| 335 RuntimeTypeGenerator runtimeTypeGenerator = | 335 RuntimeTypeGenerator runtimeTypeGenerator = |
| 336 new RuntimeTypeGenerator(_compiler, _task, namer); | 336 new RuntimeTypeGenerator(_compiler, _task, namer); |
| 337 | 337 |
| 338 void visitMember(ClassElement enclosing, Element member) { | 338 void visitMember(ClassElement enclosing, Element member) { |
| (...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 762 _registry.registerConstant(outputUnit, constantValue); | 762 _registry.registerConstant(outputUnit, constantValue); |
| 763 assert(!_constants.containsKey(constantValue)); | 763 assert(!_constants.containsKey(constantValue)); |
| 764 js.Name name = namer.constantName(constantValue); | 764 js.Name name = namer.constantName(constantValue); |
| 765 String constantObject = namer.globalObjectForConstant(constantValue); | 765 String constantObject = namer.globalObjectForConstant(constantValue); |
| 766 Holder holder = _registry.registerHolder(constantObject); | 766 Holder holder = _registry.registerHolder(constantObject); |
| 767 Constant constant = new Constant(name, holder, constantValue); | 767 Constant constant = new Constant(name, holder, constantValue); |
| 768 _constants[constantValue] = constant; | 768 _constants[constantValue] = constant; |
| 769 } | 769 } |
| 770 } | 770 } |
| 771 } | 771 } |
| OLD | NEW |