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

Unified Diff: runtime/vm/object.cc

Issue 196653004: - Fix formatting of generated sources. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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
« no previous file with comments | « no previous file | runtime/vm/object_test.cc » ('j') | runtime/vm/object_test.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
===================================================================
--- runtime/vm/object.cc (revision 33569)
+++ runtime/vm/object.cc (working copy)
@@ -6782,12 +6782,17 @@
switch (curr) {
case Token::kLBRACE:
case Token::kRBRACE:
+ if (next != Token::kNEWLINE) {
+ separator = &Symbols::Blank();
+ }
+ break;
case Token::kPERIOD:
case Token::kLBRACK:
case Token::kINTERPOL_VAR:
case Token::kINTERPOL_START:
case Token::kINTERPOL_END:
case Token::kBIT_NOT:
+ case Token::kNOT:
break;
// In case we see an opening parentheses '(' we increase the indent to
// align multi-line parameters accordingly. The indent will be removed as
@@ -6823,10 +6828,10 @@
switch (next) {
case Token::kRBRACE:
break;
+ case Token::kNEWLINE:
case Token::kSEMICOLON:
case Token::kPERIOD:
case Token::kCOMMA:
- case Token::kLPAREN:
case Token::kRPAREN:
case Token::kLBRACK:
case Token::kRBRACK:
@@ -6835,6 +6840,13 @@
case Token::kINTERPOL_END:
separator = NULL;
break;
+ case Token::kLPAREN:
+ if (curr == Token::kCATCH) {
+ separator = &Symbols::Blank();
+ } else {
+ separator = NULL;
+ }
+ break;
case Token::kELSE:
separator = &Symbols::Blank();
break;
« no previous file with comments | « no previous file | runtime/vm/object_test.cc » ('j') | runtime/vm/object_test.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698