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

Unified Diff: pkg/analyzer/tool/summary/generate.dart

Issue 1539953002: Fix "if" conditions in summary Builder setters. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 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
« no previous file with comments | « pkg/analyzer/lib/src/summary/format.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/tool/summary/generate.dart
diff --git a/pkg/analyzer/tool/summary/generate.dart b/pkg/analyzer/tool/summary/generate.dart
index 03593db7554fe86032e9483ea3b51e0df9709caf..51d499447b389862a45dd95ab969487cbf1706f8 100644
--- a/pkg/analyzer/tool/summary/generate.dart
+++ b/pkg/analyzer/tool/summary/generate.dart
@@ -332,7 +332,7 @@ class _CodeGenerator {
indent(() {
out('assert(!_finished);');
out('assert(!_json.containsKey(${quoted(fieldName)}));');
- out('if (_value != null$condition) {');
+ out('if (!(_value == null$condition)) {');
Brian Wilkerson 2015/12/18 18:16:10 The case where there is no default value got uglie
indent(() {
out('_json[${quoted(fieldName)}] = $conversion;');
});
« no previous file with comments | « pkg/analyzer/lib/src/summary/format.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698