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

Unified Diff: runtime/vm/parser.cc

Issue 2715243005: Print user-friendly name when parsing invalid redirecting constructor. (Closed)
Patch Set: Created 3 years, 10 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/parser.cc
diff --git a/runtime/vm/parser.cc b/runtime/vm/parser.cc
index 1afacf5b0017cb5c7c053202c0a0c4ff1e2e99f6..cb28f2b04d8d8a4986b77cff3887acd4d2205dcf 100644
--- a/runtime/vm/parser.cc
+++ b/runtime/vm/parser.cc
@@ -3123,9 +3123,10 @@ void Parser::ParseConstructorRedirection(const Class& cls,
if (cls.LookupFactory(ctor_name) != Function::null()) {
ReportError(call_pos,
"redirection constructor '%s' must not be a factory",
- ctor_name.ToCString());
+ String::Handle(Z, String::ScrubName(ctor_name)).ToCString());
}
- ReportError(call_pos, "constructor '%s' not found", ctor_name.ToCString());
+ ReportError(call_pos, "constructor '%s' not found",
+ String::Handle(Z, String::ScrubName(ctor_name)).ToCString());
}
if (current_function().is_const() && !redirect_ctor.is_const()) {
ReportError(call_pos, "redirection constructor '%s' must be const",
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698