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

Unified Diff: lib/compiler/implementation/tree/unparser.dart

Issue 10582038: Add null check. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/compiler/dart2js/unparser_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/tree/unparser.dart
diff --git a/lib/compiler/implementation/tree/unparser.dart b/lib/compiler/implementation/tree/unparser.dart
index b1ca8d66721bec5f2f2e90a71937cfe7b5e949e7..ea3473a514d4ce734bc9b476dd850c94d5278950 100644
--- a/lib/compiler/implementation/tree/unparser.dart
+++ b/lib/compiler/implementation/tree/unparser.dart
@@ -90,7 +90,7 @@ class Unparser implements Visitor {
// names are modelled with Send and it emits operator[] as only
// operator, without [] which are expected to be emitted with
// arguments.
- Send send = node.name.asSend();
+ Send send = node.name !== null ? node.name.asSend() : null;
ahe 2012/06/20 19:25:45 Perhaps you should change this to use: if (node.n
Anton Muhin 2012/06/20 19:34:49 Done. What's wrong w/ indentation?
if (send !== null) {
assert(send is !SendSet);
visit(send.receiver);
« no previous file with comments | « no previous file | tests/compiler/dart2js/unparser_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698