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

Unified Diff: packages/dart_style/lib/src/rule/combinator.dart

Issue 1521693002: Roll Observatory deps (charted -> ^0.3.0) (Closed) Base URL: https://chromium.googlesource.com/external/github.com/dart-lang/observatory_pub_packages.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 | « packages/dart_style/lib/src/rule/argument.dart ('k') | packages/dart_style/lib/src/rule/metadata.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packages/dart_style/lib/src/rule/combinator.dart
diff --git a/packages/dart_style/lib/src/rule/combinator.dart b/packages/dart_style/lib/src/rule/combinator.dart
index 62ddfdb3981f31691e5731a889d706474e495778..1d73031006b7ceb05632317a8d8a1cde0966b724 100644
--- a/packages/dart_style/lib/src/rule/combinator.dart
+++ b/packages/dart_style/lib/src/rule/combinator.dart
@@ -80,12 +80,8 @@ class CombinatorRule extends Rule {
_names.last.add(chunk);
}
- bool isSplit(int value, Chunk chunk) {
+ bool isSplitAtValue(int value, Chunk chunk) {
switch (value) {
- case 0:
- // Don't split at all.
- return false;
-
case 1:
// Just split at the combinators.
return _combinators.contains(chunk);
@@ -106,11 +102,9 @@ class CombinatorRule extends Rule {
// Split everything.
return true;
- case 4:
+ default:
return true;
}
-
- throw "unreachable";
}
/// Returns `true` if [chunk] is for a combinator or a name in the
« no previous file with comments | « packages/dart_style/lib/src/rule/argument.dart ('k') | packages/dart_style/lib/src/rule/metadata.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698