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

Unified Diff: pkg/compiler/lib/src/ssa/optimize.dart

Issue 2791993002: Fix dart2js warnings and add test to ensure it stays clean. (Closed)
Patch Set: Remove unused method. Created 3 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 side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/ssa/optimize.dart
diff --git a/pkg/compiler/lib/src/ssa/optimize.dart b/pkg/compiler/lib/src/ssa/optimize.dart
index b85a680e99da97fb49b8d6449f4954b0fe22d643..176179e0d33ec5dd2e35463824007496f51b0f3a 100644
--- a/pkg/compiler/lib/src/ssa/optimize.dart
+++ b/pkg/compiler/lib/src/ssa/optimize.dart
@@ -518,7 +518,9 @@ class SsaInstructionSimplifier extends HBaseVisitor
!node.isCallOnInterceptor(_closedWorld)) {
HInstruction receiver = node.getDartReceiver(_closedWorld);
TypeMask type = TypeMaskFactory.inferredTypeForMember(
- field as Entity, _globalInferenceResults);
+ // ignore: ARGUMENT_TYPE_NOT_ASSIGNABLE
+ field,
Johnni Winther 2017/04/03 12:07:33 Reinsert the cast and ignore the hint.
ahe 2017/04/03 12:25:07 Done.
+ _globalInferenceResults);
HInstruction load = new HFieldGet(field, receiver, type);
node.block.addBefore(node, load);
Selector callSelector = new Selector.callClosureFrom(node.selector);
@@ -995,7 +997,9 @@ class SsaInstructionSimplifier extends HBaseVisitor
_nativeData.getNativeFieldLoadBehavior(field), _closedWorld);
} else {
type = TypeMaskFactory.inferredTypeForMember(
- field as Entity, _globalInferenceResults);
+ // ignore: ARGUMENT_TYPE_NOT_ASSIGNABLE
+ field,
Johnni Winther 2017/04/03 12:07:33 Reinsert the cast and ignore the hint.
ahe 2017/04/03 12:25:07 Done.
+ _globalInferenceResults);
}
return new HFieldGet(field, receiver, type, isAssignable: isAssignable);
@@ -2379,7 +2383,11 @@ class SsaLoadElimination extends HBaseVisitor implements OptimizationPhase {
int argumentIndex = 0;
compiler.codegenWorldBuilder.forEachInstanceField(instruction.element,
(_, FieldEntity member) {
- if (compiler.elementHasCompileTimeError(member as Entity)) return;
+ if (compiler.elementHasCompileTimeError(
+ // ignore: ARGUMENT_TYPE_NOT_ASSIGNABLE
+ member)) {
Johnni Winther 2017/04/03 12:07:33 Reinsert the cast and ignore the hint.
ahe 2017/04/03 12:25:07 Done.
+ return;
+ }
memorySet.registerFieldValue(
member, instruction, instruction.inputs[argumentIndex++]);
});

Powered by Google App Engine
This is Rietveld 408576698