Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(529)

Side by Side Diff: pkg/compiler/lib/src/js_emitter/program_builder.dart

Issue 1019903002: Revert "Don't generate forwarding hooks if all noSuchMethod implementations" (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 callStubs.add(_buildStubMethod(name, code, element: member)); 351 callStubs.add(_buildStubMethod(name, code, element: member));
352 }); 352 });
353 } 353 }
354 } 354 }
355 } 355 }
356 356
357 List<StubMethod> typeVariableReaderStubs = 357 List<StubMethod> typeVariableReaderStubs =
358 runtimeTypeGenerator.generateTypeVariableReaderStubs(element); 358 runtimeTypeGenerator.generateTypeVariableReaderStubs(element);
359 359
360 List<StubMethod> noSuchMethodStubs = <StubMethod>[]; 360 List<StubMethod> noSuchMethodStubs = <StubMethod>[];
361 if (backend.enabledNoSuchMethod && element == _compiler.objectClass) { 361 if (_compiler.enabledNoSuchMethod && element == _compiler.objectClass) {
362 Map<String, Selector> selectors = 362 Map<String, Selector> selectors =
363 classStubGenerator.computeSelectorsForNsmHandlers(); 363 classStubGenerator.computeSelectorsForNsmHandlers();
364 selectors.forEach((String name, Selector selector) { 364 selectors.forEach((String name, Selector selector) {
365 noSuchMethodStubs 365 noSuchMethodStubs
366 .add(classStubGenerator.generateStubForNoSuchMethod(name, 366 .add(classStubGenerator.generateStubForNoSuchMethod(name,
367 selector)); 367 selector));
368 }); 368 });
369 } 369 }
370 370
371 if (element == backend.closureClass) { 371 if (element == backend.closureClass) {
(...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 _registry.registerConstant(outputUnit, constantValue); 754 _registry.registerConstant(outputUnit, constantValue);
755 assert(!_constants.containsKey(constantValue)); 755 assert(!_constants.containsKey(constantValue));
756 String name = namer.constantName(constantValue); 756 String name = namer.constantName(constantValue);
757 String constantObject = namer.globalObjectForConstant(constantValue); 757 String constantObject = namer.globalObjectForConstant(constantValue);
758 Holder holder = _registry.registerHolder(constantObject); 758 Holder holder = _registry.registerHolder(constantObject);
759 Constant constant = new Constant(name, holder, constantValue); 759 Constant constant = new Constant(name, holder, constantValue);
760 _constants[constantValue] = constant; 760 _constants[constantValue] = constant;
761 } 761 }
762 } 762 }
763 } 763 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698