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

Side by Side Diff: pkg/compiler/lib/src/common_elements.dart

Issue 2873633002: Pass data objects to ConstantEmitter (Closed)
Patch Set: Created 3 years, 7 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
« no previous file with comments | « no previous file | pkg/compiler/lib/src/js_backend/constant_emitter.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // TODO(sigmund): rename and move to common/elements.dart 5 // TODO(sigmund): rename and move to common/elements.dart
6 library dart2js.type_system; 6 library dart2js.type_system;
7 7
8 import 'common/names.dart' show Identifiers, Uris; 8 import 'common/names.dart' show Identifiers, Uris;
9 import 'constants/values.dart'; 9 import 'constants/values.dart';
10 import 'elements/entities.dart'; 10 import 'elements/entities.dart';
(...skipping 721 matching lines...) Expand 10 before | Expand all | Expand 10 after
732 _jsStringSplit ??= _findClassMember(jsStringClass, 'split'); 732 _jsStringSplit ??= _findClassMember(jsStringClass, 'split');
733 733
734 FunctionEntity _jsStringToString; 734 FunctionEntity _jsStringToString;
735 FunctionEntity get jsStringToString => 735 FunctionEntity get jsStringToString =>
736 _jsStringToString ??= _findClassMember(jsStringClass, 'toString'); 736 _jsStringToString ??= _findClassMember(jsStringClass, 'toString');
737 737
738 FunctionEntity _jsStringOperatorAdd; 738 FunctionEntity _jsStringOperatorAdd;
739 FunctionEntity get jsStringOperatorAdd => 739 FunctionEntity get jsStringOperatorAdd =>
740 _jsStringOperatorAdd ??= _findClassMember(jsStringClass, '+'); 740 _jsStringOperatorAdd ??= _findClassMember(jsStringClass, '+');
741 741
742 ClassEntity _jsConstClass;
743 ClassEntity get jsConstClass =>
744 _jsConstClass ??= _findClass(foreignLibrary, 'JS_CONST');
745
742 // From package:js 746 // From package:js
743 ClassEntity _jsAnnotationClass; 747 ClassEntity _jsAnnotationClass;
744 ClassEntity get jsAnnotationClass { 748 ClassEntity get jsAnnotationClass {
745 if (_jsAnnotationClass == null) { 749 if (_jsAnnotationClass == null) {
746 LibraryEntity library = _env.lookupLibrary(Uris.package_js); 750 LibraryEntity library = _env.lookupLibrary(Uris.package_js);
747 if (library == null) return null; 751 if (library == null) return null;
748 _jsAnnotationClass = _findClass(library, 'JS'); 752 _jsAnnotationClass = _findClass(library, 'JS');
749 } 753 }
750 return _jsAnnotationClass; 754 return _jsAnnotationClass;
751 } 755 }
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after
1261 /// arguments, both required and optional. 1265 /// arguments, both required and optional.
1262 CallStructure getCallStructure(FunctionEntity entity); 1266 CallStructure getCallStructure(FunctionEntity entity);
1263 1267
1264 /// Returns `true` if [member] a the synthetic getter `loadLibrary` injected 1268 /// Returns `true` if [member] a the synthetic getter `loadLibrary` injected
1265 /// on deferred libraries. 1269 /// on deferred libraries.
1266 bool isDeferredLoadLibraryGetter(MemberEntity member); 1270 bool isDeferredLoadLibraryGetter(MemberEntity member);
1267 1271
1268 /// Returns the metadata constants declared on [member]. 1272 /// Returns the metadata constants declared on [member].
1269 Iterable<ConstantValue> getMemberMetadata(MemberEntity member); 1273 Iterable<ConstantValue> getMemberMetadata(MemberEntity member);
1270 } 1274 }
OLDNEW
« no previous file with comments | « no previous file | pkg/compiler/lib/src/js_backend/constant_emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698