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

Unified Diff: pkg/front_end/lib/src/fasta/builder/modifier_builder.dart

Issue 2972543003: Implement toString on ModifierBuilder. (Closed)
Patch Set: Created 3 years, 5 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
Index: pkg/front_end/lib/src/fasta/builder/modifier_builder.dart
diff --git a/pkg/front_end/lib/src/fasta/builder/modifier_builder.dart b/pkg/front_end/lib/src/fasta/builder/modifier_builder.dart
index fe46212c634eb8a0f43ccbc43b0699dfabf4a83a..114a9f680a6d125ccf3ee658ac859ec203fd16bf 100644
--- a/pkg/front_end/lib/src/fasta/builder/modifier_builder.dart
+++ b/pkg/front_end/lib/src/fasta/builder/modifier_builder.dart
@@ -42,4 +42,12 @@ abstract class ModifierBuilder extends Builder {
String get name;
bool get isNative => false;
+
+ String get debugName;
+
+ StringBuffer printOn(StringBuffer buffer) {
+ return buffer..write(name ?? fullNameForErrors);
+ }
+
+ String toString() => "$debugName(${printOn(new StringBuffer())})";
}

Powered by Google App Engine
This is Rietveld 408576698