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

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

Issue 2791263005: Split MirrorsData methods and MirrorsDataImpl data by element kind. (Closed)
Patch Set: Updated cf. comments. Created 3 years, 8 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
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 '../../closure.dart' show ClosureFieldElement; 7 import '../../closure.dart' show ClosureFieldElement;
8 import '../../common.dart'; 8 import '../../common.dart';
9 import '../../common/names.dart' show Names, Selectors; 9 import '../../common/names.dart' show Names, Selectors;
10 import '../../compiler.dart' show Compiler; 10 import '../../compiler.dart' show Compiler;
(...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after
651 isNative: backend.nativeData.isNativeClass(element)); 651 isNative: backend.nativeData.isNativeClass(element));
652 } 652 }
653 _classes[element] = result; 653 _classes[element] = result;
654 return result; 654 return result;
655 } 655 }
656 656
657 bool _methodNeedsStubs(FunctionElement method) { 657 bool _methodNeedsStubs(FunctionElement method) {
658 return !method.functionSignature.optionalParameters.isEmpty; 658 return !method.functionSignature.optionalParameters.isEmpty;
659 } 659 }
660 660
661 bool _methodCanBeReflected(FunctionElement method) { 661 bool _methodCanBeReflected(MethodElement method) {
662 return backend.mirrorsData.isAccessibleByReflection(method); 662 return backend.mirrorsData.isMemberAccessibleByReflection(method);
663 } 663 }
664 664
665 bool _methodCanBeApplied(FunctionElement method) { 665 bool _methodCanBeApplied(FunctionElement method) {
666 return backend.backendUsage.isFunctionApplyUsed && 666 return backend.backendUsage.isFunctionApplyUsed &&
667 closedWorld.getMightBePassedToApply(method); 667 closedWorld.getMightBePassedToApply(method);
668 } 668 }
669 669
670 /* Map | List */ _computeParameterDefaultValues(FunctionSignature signature) { 670 /* Map | List */ _computeParameterDefaultValues(FunctionSignature signature) {
671 var /* Map | List */ optionalParameterDefaultValues; 671 var /* Map | List */ optionalParameterDefaultValues;
672 if (signature.optionalParametersAreNamed) { 672 if (signature.optionalParametersAreNamed) {
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
972 Constant constant = new Constant(name, holder, constantValue); 972 Constant constant = new Constant(name, holder, constantValue);
973 _constants[constantValue] = constant; 973 _constants[constantValue] = constant;
974 } 974 }
975 } 975 }
976 976
977 Holder _registerStaticStateHolder() { 977 Holder _registerStaticStateHolder() {
978 return _registry.registerHolder(namer.staticStateHolder, 978 return _registry.registerHolder(namer.staticStateHolder,
979 isStaticStateHolder: true); 979 isStaticStateHolder: true);
980 } 980 }
981 } 981 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698