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

Side by Side Diff: pkg/compiler/lib/src/js_backend/backend.dart

Issue 1971193002: Patches to support Dart VM patch files in dart2js. (Closed) Base URL: sso://user/ahe/dart-sdk@master
Patch Set: Created 4 years, 6 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 | « pkg/compiler/lib/src/compiler.dart ('k') | pkg/compiler/lib/src/js_backend/patch_resolver.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) 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 const VERBOSE_OPTIMIZER_HINTS = false; 7 const VERBOSE_OPTIMIZER_HINTS = false;
8 8
9 class JavaScriptItemCompilationContext extends ItemCompilationContext { 9 class JavaScriptItemCompilationContext extends ItemCompilationContext {
10 final Set<HInstruction> boundsChecked = new Set<HInstruction>(); 10 final Set<HInstruction> boundsChecked = new Set<HInstruction>();
(...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after
570 return element; 570 return element;
571 } 571 }
572 if (isJsInterop(element)) { 572 if (isJsInterop(element)) {
573 if (element.memberName == const PublicName('[]') || 573 if (element.memberName == const PublicName('[]') ||
574 element.memberName == const PublicName('[]=')) { 574 element.memberName == const PublicName('[]=')) {
575 reporter.reportErrorMessage( 575 reporter.reportErrorMessage(
576 element, MessageKind.JS_INTEROP_INDEX_NOT_SUPPORTED); 576 element, MessageKind.JS_INTEROP_INDEX_NOT_SUPPORTED);
577 } 577 }
578 return element; 578 return element;
579 } 579 }
580 return patchResolverTask.measure(() { 580 return patchResolverTask.resolveExternalFunction(element);
581 return patchResolverTask.resolveExternalFunction(element);
582 });
583 } 581 }
584 582
585 bool isForeign(Element element) => element.library == helpers.foreignLibrary; 583 bool isForeign(Element element) => element.library == helpers.foreignLibrary;
586 584
587 bool isBackendLibrary(LibraryElement library) { 585 bool isBackendLibrary(LibraryElement library) {
588 return library == helpers.interceptorsLibrary || 586 return library == helpers.interceptorsLibrary ||
589 library == helpers.jsHelperLibrary; 587 library == helpers.jsHelperLibrary;
590 } 588 }
591 589
592 static Namer determineNamer(Compiler compiler) { 590 static Namer determineNamer(Compiler compiler) {
(...skipping 2389 matching lines...) Expand 10 before | Expand all | Expand 10 after
2982 2980
2983 @override 2981 @override
2984 void onImpactUsed(ImpactUseCase impactUse) { 2982 void onImpactUsed(ImpactUseCase impactUse) {
2985 if (impactUse == DeferredLoadTask.IMPACT_USE && !supportSerialization) { 2983 if (impactUse == DeferredLoadTask.IMPACT_USE && !supportSerialization) {
2986 // TODO(johnniwinther): Allow emptying when serialization has been 2984 // TODO(johnniwinther): Allow emptying when serialization has been
2987 // performed. 2985 // performed.
2988 resolution.emptyCache(); 2986 resolution.emptyCache();
2989 } 2987 }
2990 } 2988 }
2991 } 2989 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/compiler.dart ('k') | pkg/compiler/lib/src/js_backend/patch_resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698