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

Unified Diff: pkg/compiler/lib/src/diagnostics/messages.dart

Issue 2535213003: Support patched generic methods. (Closed)
Patch Set: Add tests for renaming. Created 4 years, 1 month 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 | pkg/compiler/lib/src/elements/elements.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/diagnostics/messages.dart
diff --git a/pkg/compiler/lib/src/diagnostics/messages.dart b/pkg/compiler/lib/src/diagnostics/messages.dart
index a65c6ef83a9976f467c5ab8bee0927a76c02332a..4b6e33adca3c88625adcddd2edc7e0cfcb7ca5eb 100644
--- a/pkg/compiler/lib/src/diagnostics/messages.dart
+++ b/pkg/compiler/lib/src/diagnostics/messages.dart
@@ -385,6 +385,7 @@ enum MessageKind {
PATCH_POINT_TO_SETTER,
PATCH_REQUIRED_PARAMETER_COUNT_MISMATCH,
PATCH_RETURN_TYPE_MISMATCH,
+ PATCH_TYPE_VARIABLES_MISMATCH,
PLEASE_REPORT_THE_CRASH,
POSITIONAL_PARAMETER_WITH_EQUALS,
POTENTIAL_MUTATION,
@@ -1239,12 +1240,14 @@ main() => f<int>(42);
]),
MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC:
- const MessageTemplate(
- MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC,
- "Method type variables are treated as `dynamic` in `as` expressions.",
- howToFix: "Try using the upper bound of the type variable, or check "
- "that the blind success of the test does not introduce bugs.",
- examples: const [
+ const MessageTemplate(
+ MessageKind.TYPE_VARIABLE_FROM_METHOD_CONSIDERED_DYNAMIC,
+ "Method type variables are treated as `dynamic` in `as` "
+ "expressions.",
+ howToFix:
+ "Try using the upper bound of the type variable, or check "
+ "that the blind success of the test does not introduce bugs.",
+ examples: const [
"""
// Method type variables are not reified, so they cannot be tested dynamically.
bool f<T>(Object o) => o as T;
@@ -3530,6 +3533,11 @@ part of test.main;
// Patch errors start.
//////////////////////////////////////////////////////////////////////////////
+ MessageKind.PATCH_TYPE_VARIABLES_MISMATCH: const MessageTemplate(
+ MessageKind.PATCH_TYPE_VARIABLES_MISMATCH,
+ "Patch type variables do not match "
+ "type variables on origin method '#{methodName}'."),
+
MessageKind.PATCH_RETURN_TYPE_MISMATCH: const MessageTemplate(
MessageKind.PATCH_RETURN_TYPE_MISMATCH,
"Patch return type '#{patchReturnType}' does not match "
« no previous file with comments | « no previous file | pkg/compiler/lib/src/elements/elements.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698