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

Unified Diff: sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart

Issue 11412245: MalformedType used for all invalid type annotations. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebased Created 8 years 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: sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart
diff --git a/sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart b/sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart
index 24859f4358a7b7a3c3f0cdab8da7715518357a2c..487736f354d45dc33eb25700f39dc092593c0c43 100644
--- a/sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart
+++ b/sdk/lib/_internal/compiler/implementation/dart_backend/placeholder_collector.dart
@@ -365,14 +365,7 @@ class PlaceholderCollector extends Visitor {
Element constructor = treeElements[send];
assert(constructor != null);
assert(send.receiver == null);
-
- // For constructors that refer to malformed class types retrieve
- // class type like it is done in [ SsaBuilder.visitNewSend ].
- if (type.kind == TypeKind.MALFORMED_TYPE) {
- type = constructor.getEnclosingClass().thisType;
- }
-
- if (!Elements.isUnresolved(constructor)) {
+ if (!Elements.isErroneousElement(constructor)) {
makeConstructorPlaceholder(node.send.selector, constructor, type);
// TODO(smok): Should this be in visitNamedArgument?
// Field names can be exposed as names of optional arguments, e.g.

Powered by Google App Engine
This is Rietveld 408576698