[analyzer] Improve null handling in LSP server
Change-Id: I2060912853d131fad1d02ddc68f0b62ab16e3b23
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/196123
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
index 046c9c0..03f9e6a 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
@@ -38,7 +38,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('isAnalyzing');
try {
@@ -105,7 +105,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -197,7 +197,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('file');
try {
@@ -313,7 +313,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('libId');
try {
@@ -492,7 +492,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('port');
try {
@@ -590,7 +590,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -782,7 +782,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -973,7 +973,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -1090,7 +1090,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('element');
try {
@@ -1218,7 +1218,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('packageName');
try {
@@ -1328,7 +1328,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -1419,7 +1419,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -1504,7 +1504,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -1602,7 +1602,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('insertTextFormat');
try {
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
index 48503cb..b88f7cc 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
@@ -54,7 +54,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('annotationId');
try {
@@ -165,7 +165,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -263,7 +263,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('applied');
try {
@@ -358,7 +358,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -425,7 +425,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('from');
try {
@@ -545,7 +545,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('item');
try {
@@ -701,7 +701,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -873,7 +873,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -940,7 +940,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('to');
try {
@@ -1060,7 +1060,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('item');
try {
@@ -1175,7 +1175,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -1300,7 +1300,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -1393,7 +1393,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -1480,7 +1480,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -1617,7 +1617,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workspace');
try {
@@ -1777,7 +1777,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -1919,7 +1919,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('regularExpressions');
try {
@@ -2021,7 +2021,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -2231,7 +2231,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('applyEdit');
try {
@@ -2529,7 +2529,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('title');
try {
@@ -2748,7 +2748,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -2889,7 +2889,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -2965,7 +2965,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('codeActionKind');
try {
@@ -3037,7 +3037,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('properties');
try {
@@ -3129,7 +3129,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('diagnostics');
try {
@@ -3214,7 +3214,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('reason');
try {
@@ -3381,7 +3381,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('codeActionKinds');
try {
@@ -3515,7 +3515,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -3686,7 +3686,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -3793,7 +3793,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('href');
try {
@@ -3880,7 +3880,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -3961,7 +3961,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -4030,7 +4030,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('resolveProvider');
try {
@@ -4134,7 +4134,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -4247,7 +4247,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -4347,7 +4347,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('refreshSupport');
try {
@@ -4424,7 +4424,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('red');
try {
@@ -4551,7 +4551,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -4662,7 +4662,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -4802,7 +4802,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -4944,7 +4944,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('title');
try {
@@ -5079,7 +5079,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -5286,7 +5286,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('snippetSupport');
try {
@@ -5463,7 +5463,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -5531,7 +5531,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -5605,7 +5605,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('properties');
try {
@@ -5679,7 +5679,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -5760,7 +5760,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('triggerKind');
try {
@@ -6071,7 +6071,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -6420,7 +6420,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('isIncomplete');
try {
@@ -6563,7 +6563,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('triggerCharacters');
try {
@@ -6719,7 +6719,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('context');
try {
@@ -6906,7 +6906,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -7074,7 +7074,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('scopeUri');
try {
@@ -7142,7 +7142,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('items');
try {
@@ -7243,7 +7243,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -7361,7 +7361,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('overwrite');
try {
@@ -7435,7 +7435,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('files');
try {
@@ -7516,7 +7516,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -7590,7 +7590,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -7693,7 +7693,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -7830,7 +7830,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -7931,7 +7931,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -8005,7 +8005,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -8107,7 +8107,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -8229,7 +8229,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -8339,7 +8339,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -8457,7 +8457,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('recursive');
try {
@@ -8532,7 +8532,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('files');
try {
@@ -8692,7 +8692,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -8868,7 +8868,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('location');
try {
@@ -9023,7 +9023,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -9083,7 +9083,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
return true;
} else {
@@ -9167,7 +9167,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -9275,7 +9275,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -9338,7 +9338,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('changes');
try {
@@ -9413,7 +9413,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('watchers');
try {
@@ -9484,7 +9484,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('event');
try {
@@ -9549,7 +9549,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -9614,7 +9614,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -9687,7 +9687,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -9766,7 +9766,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -9828,7 +9828,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -9920,7 +9920,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -10039,7 +10039,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -10156,7 +10156,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('language');
try {
@@ -10240,7 +10240,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -10304,7 +10304,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -10384,7 +10384,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -10499,7 +10499,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -10590,7 +10590,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -10670,7 +10670,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -10766,7 +10766,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -10869,7 +10869,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -10997,7 +10997,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -11107,7 +11107,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -11210,7 +11210,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -11291,7 +11291,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('resolveProvider');
try {
@@ -11396,7 +11396,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -11513,7 +11513,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -11608,7 +11608,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -11685,7 +11685,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('firstTriggerCharacter');
try {
@@ -11791,7 +11791,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('ch');
try {
@@ -11945,7 +11945,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -12051,7 +12051,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -12117,7 +12117,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -12208,7 +12208,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -12342,7 +12342,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -12498,7 +12498,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -12726,7 +12726,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -12850,7 +12850,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -12918,7 +12918,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -13001,7 +13001,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -13105,7 +13105,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -13224,7 +13224,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -13370,7 +13370,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -13438,7 +13438,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('commands');
try {
@@ -13541,7 +13541,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('command');
try {
@@ -13645,7 +13645,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('commands');
try {
@@ -13805,7 +13805,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -13871,7 +13871,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -13941,7 +13941,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -14033,7 +14033,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('scheme');
try {
@@ -14141,7 +14141,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('glob');
try {
@@ -14266,7 +14266,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('ignoreCase');
try {
@@ -14329,7 +14329,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('filters');
try {
@@ -14405,7 +14405,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('oldUri');
try {
@@ -14507,7 +14507,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('globPattern');
try {
@@ -14631,7 +14631,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('startLine');
try {
@@ -14777,7 +14777,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -14894,7 +14894,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -14986,7 +14986,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -15105,7 +15105,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -15234,7 +15234,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('tabSize');
try {
@@ -15367,7 +15367,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('contents');
try {
@@ -15459,7 +15459,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -15537,7 +15537,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -15617,7 +15617,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -15725,7 +15725,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -15818,7 +15818,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -15892,7 +15892,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -15995,7 +15995,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -16133,7 +16133,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -16332,7 +16332,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('processId');
try {
@@ -16513,7 +16513,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -16598,7 +16598,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('capabilities');
try {
@@ -16683,7 +16683,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -16752,7 +16752,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
return true;
} else {
@@ -16812,7 +16812,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('newText');
try {
@@ -16999,7 +16999,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -17063,7 +17063,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -17144,7 +17144,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -17270,7 +17270,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -17374,7 +17374,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('ranges');
try {
@@ -17454,7 +17454,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -17571,7 +17571,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('originSelectionRange');
try {
@@ -17691,7 +17691,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('type');
try {
@@ -17781,7 +17781,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('message');
try {
@@ -17864,7 +17864,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('parser');
try {
@@ -17965,7 +17965,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -18091,7 +18091,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('jsonrpc');
try {
@@ -18155,7 +18155,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('title');
try {
@@ -18549,7 +18549,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('scheme');
try {
@@ -18669,7 +18669,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -18763,7 +18763,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -18865,7 +18865,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -18986,7 +18986,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -19077,7 +19077,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('method');
try {
@@ -19180,7 +19180,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('version');
try {
@@ -19287,7 +19287,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -19442,7 +19442,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('partialResultToken');
try {
@@ -19511,7 +19511,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('line');
try {
@@ -19598,7 +19598,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -19718,7 +19718,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('token');
try {
@@ -19836,7 +19836,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('relatedInformation');
try {
@@ -19949,7 +19949,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -20038,7 +20038,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -20141,7 +20141,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('start');
try {
@@ -20225,7 +20225,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -20312,7 +20312,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -20370,7 +20370,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('includeDeclaration');
try {
@@ -20438,7 +20438,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -20546,7 +20546,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('context');
try {
@@ -20687,7 +20687,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -20780,7 +20780,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -20869,7 +20869,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('registrations');
try {
@@ -20949,7 +20949,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('engine');
try {
@@ -21071,7 +21071,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -21209,7 +21209,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -21346,7 +21346,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('overwrite');
try {
@@ -21421,7 +21421,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('files');
try {
@@ -21500,7 +21500,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('prepareProvider');
try {
@@ -21603,7 +21603,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('newName');
try {
@@ -21740,7 +21740,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -21854,7 +21854,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -22009,7 +22009,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('code');
try {
@@ -22131,7 +22131,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -22227,7 +22227,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('includeText');
try {
@@ -22292,7 +22292,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -22374,7 +22374,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -22436,7 +22436,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -22538,7 +22538,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -22679,7 +22679,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -22836,12 +22836,12 @@
SemanticTokens({this.resultId, required this.data});
static SemanticTokens fromJson(Map<String, dynamic> json) {
final resultId = json['resultId'];
- final data = json['data']?.map((item) => item)?.cast<num>()?.toList();
+ final data = json['data']?.map((item) => item)?.cast<int>()?.toList();
return SemanticTokens(resultId: resultId, data: data);
}
/// The actual tokens.
- final List<num> data;
+ final List<int> data;
/// An optional result id. If provided and clients support delta updating the
/// client will include the result id in the next semantic token request. A
@@ -22858,7 +22858,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('resultId');
try {
@@ -22880,8 +22880,8 @@
return false;
}
if (!((obj['data'] is List &&
- (obj['data'].every((item) => item is num))))) {
- reporter.reportError('must be of type List<num>');
+ (obj['data'].every((item) => item is int))))) {
+ reporter.reportError('must be of type List<int>');
return false;
}
} finally {
@@ -22898,7 +22898,7 @@
bool operator ==(Object other) {
if (other is SemanticTokens && other.runtimeType == SemanticTokens) {
return resultId == other.resultId &&
- listEqual(data, other.data, (num a, num b) => a == b) &&
+ listEqual(data, other.data, (int a, int b) => a == b) &&
true;
}
return false;
@@ -23002,7 +23002,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -23175,7 +23175,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('delta');
try {
@@ -23229,7 +23229,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
return true;
} else {
@@ -23309,7 +23309,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -23393,7 +23393,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('resultId');
try {
@@ -23515,7 +23515,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -23629,7 +23629,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('edits');
try {
@@ -23712,7 +23712,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('start');
try {
@@ -23819,7 +23819,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('tokenTypes');
try {
@@ -23952,7 +23952,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('legend');
try {
@@ -24060,7 +24060,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('delta');
try {
@@ -24111,7 +24111,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
return true;
} else {
@@ -24192,7 +24192,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -24284,7 +24284,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('data');
try {
@@ -24391,7 +24391,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -24573,7 +24573,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -24720,7 +24720,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('refreshSupport');
try {
@@ -25328,7 +25328,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocumentSync');
try {
@@ -25863,7 +25863,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('didCreate');
try {
@@ -26011,7 +26011,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workspaceFolders');
try {
@@ -26088,7 +26088,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('value');
try {
@@ -26157,7 +26157,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('support');
try {
@@ -26257,7 +26257,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -26359,7 +26359,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('success');
try {
@@ -26429,7 +26429,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('type');
try {
@@ -26521,7 +26521,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('messageActionItem');
try {
@@ -26590,7 +26590,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('additionalPropertiesSupport');
try {
@@ -26668,7 +26668,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('type');
try {
@@ -26805,7 +26805,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('signatures');
try {
@@ -26929,7 +26929,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -27022,7 +27022,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('labelOffsetSupport');
try {
@@ -27118,7 +27118,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentationFormat');
try {
@@ -27250,7 +27250,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('triggerKind');
try {
@@ -27393,7 +27393,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('triggerCharacters');
try {
@@ -27520,7 +27520,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('context');
try {
@@ -27676,7 +27676,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -27865,7 +27865,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('label');
try {
@@ -28004,7 +28004,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -28122,7 +28122,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('name');
try {
@@ -28353,7 +28353,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('syncKind');
try {
@@ -28738,7 +28738,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('synchronization');
try {
@@ -29152,7 +29152,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -29249,7 +29249,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('text');
try {
@@ -29334,7 +29334,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -29438,7 +29438,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -29524,7 +29524,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -29698,7 +29698,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -29874,7 +29874,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -29989,7 +29989,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('includeText');
try {
@@ -30102,7 +30102,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -30285,7 +30285,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('openClose');
try {
@@ -30403,7 +30403,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('range');
try {
@@ -30523,7 +30523,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -30597,7 +30597,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -30700,7 +30700,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -30838,7 +30838,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentSelector');
try {
@@ -30971,7 +30971,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('id');
try {
@@ -31059,7 +31059,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('unregisterations');
try {
@@ -31138,7 +31138,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('version');
try {
@@ -31259,7 +31259,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('textDocument');
try {
@@ -31396,7 +31396,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -31519,7 +31519,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('token');
try {
@@ -31589,7 +31589,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('token');
try {
@@ -31665,7 +31665,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -31816,7 +31816,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -31975,7 +31975,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneToken');
try {
@@ -32076,7 +32076,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('kind');
try {
@@ -32241,7 +32241,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('changes');
try {
@@ -32407,7 +32407,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('documentChanges');
try {
@@ -32527,7 +32527,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('groupsOnLabel');
try {
@@ -32592,7 +32592,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('uri');
try {
@@ -32687,7 +32687,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('added');
try {
@@ -32802,7 +32802,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('supported');
try {
@@ -32904,7 +32904,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('dynamicRegistration');
try {
@@ -33003,7 +33003,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -33071,7 +33071,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('valueSet');
try {
@@ -33146,7 +33146,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
@@ -33238,7 +33238,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('query');
try {
@@ -33335,7 +33335,7 @@
return __result;
}
- static bool canParse(Object obj, LspJsonReporter reporter) {
+ static bool canParse(Object? obj, LspJsonReporter reporter) {
if (obj is Map<String, dynamic>) {
reporter.push('workDoneProgress');
try {
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
index 9ee8f63..9d6fe11 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
@@ -266,9 +266,9 @@
/// A helper to allow handlers to declare both a JSON validation function and
/// parse function.
class LspJsonHandler<T> {
- final bool Function(Map<String, Object>, LspJsonReporter reporter)
+ final bool Function(Map<String, Object?>?, LspJsonReporter reporter)
validateParams;
- final T Function(Map<String, Object>) convertParams;
+ final T Function(Map<String, Object?>) convertParams;
const LspJsonHandler(this.validateParams, this.convertParams);
}
diff --git a/pkg/analysis_server/lib/src/lsp/client_configuration.dart b/pkg/analysis_server/lib/src/lsp/client_configuration.dart
index 26ad2d0..332330f 100644
--- a/pkg/analysis_server/lib/src/lsp/client_configuration.dart
+++ b/pkg/analysis_server/lib/src/lsp/client_configuration.dart
@@ -22,7 +22,7 @@
bool get completeFunctionCalls => _settings['completeFunctionCalls'] ?? false;
bool get enableSdkFormatter => _settings['enableSdkFormatter'] ?? true;
- int get lineLength => _settings['lineLength'];
+ int? get lineLength => _settings['lineLength'];
/// A preview flag for enabling commit characters for completions.
///
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
index fff5d0c..99357b7 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
@@ -45,10 +45,10 @@
String kind = arguments[0];
String path = arguments[1];
- int docVersion = arguments[2];
+ int? docVersion = arguments[2];
int offset = arguments[3];
int length = arguments[4];
- Map<String, dynamic> options = arguments[5];
+ Map<String, dynamic>? options = arguments[5];
final result = await requireResolvedUnit(path);
return result.mapResult((result) async {
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_exit.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_exit.dart
index a5850a5..ca28963 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_exit.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_exit.dart
@@ -9,7 +9,7 @@
import 'package:analysis_server/src/lsp/handlers/handlers.dart';
import 'package:analysis_server/src/lsp/lsp_analysis_server.dart';
-class ExitMessageHandler extends MessageHandler<void, void> {
+class ExitMessageHandler extends MessageHandler<Null, Null> {
final bool clientDidCallShutdown;
ExitMessageHandler(
@@ -21,10 +21,10 @@
Method get handlesMessage => Method.exit;
@override
- LspJsonHandler<void> get jsonHandler => NullJsonHandler;
+ LspJsonHandler<Null> get jsonHandler => NullJsonHandler;
@override
- Future<ErrorOr<void>> handle(void _, CancellationToken token) async {
+ Future<ErrorOr<Null>> handle(Null _, CancellationToken token) async {
// Set a flag that the server shutdown is being controlled here to ensure
// that the normal code that shuts down the server when the channel closes
// does not fire.
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_reject.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_reject.dart
index dbcefeb..6e82230 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_reject.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_reject.dart
@@ -9,7 +9,7 @@
/// A [MessageHandler] that rejects specific tpyes of messages with a given
/// error code/message.
-class RejectMessageHandler extends MessageHandler<Object?, void> {
+class RejectMessageHandler extends MessageHandler<Object?, Null> {
@override
final Method handlesMessage;
final ErrorCodes errorCode;
@@ -19,10 +19,10 @@
: super(server);
@override
- LspJsonHandler<Object?> get jsonHandler => NullJsonHandler;
+ LspJsonHandler<Null> get jsonHandler => NullJsonHandler;
@override
- ErrorOr<void> handle(void _, CancellationToken token) {
+ ErrorOr<Null> handle(Object? _, CancellationToken token) {
return error(errorCode, errorMessage, null);
}
}
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_shutdown.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_shutdown.dart
index b226c29..df1ff6c 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_shutdown.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_shutdown.dart
@@ -8,16 +8,16 @@
import 'package:analysis_server/src/lsp/handlers/handlers.dart';
import 'package:analysis_server/src/lsp/lsp_analysis_server.dart';
-class ShutdownMessageHandler extends MessageHandler<void, void> {
+class ShutdownMessageHandler extends MessageHandler<Null, Null> {
ShutdownMessageHandler(LspAnalysisServer server) : super(server);
@override
Method get handlesMessage => Method.shutdown;
@override
- LspJsonHandler<void> get jsonHandler => NullJsonHandler;
+ LspJsonHandler<Null> get jsonHandler => NullJsonHandler;
@override
- ErrorOr<void> handle(void _, CancellationToken token) {
+ ErrorOr<Null> handle(void _, CancellationToken token) {
// Move to the Shutting Down state so we won't process any more
// requests and the Exit notification will know it was a clean shutdown.
server.messageHandler = ShuttingDownStateMessageHandler(server);
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handlers.dart b/pkg/analysis_server/lib/src/lsp/handlers/handlers.dart
index 6e31bf2..89db7cc 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handlers.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handlers.dart
@@ -144,7 +144,9 @@
);
}
- final params = jsonHandler.convertParams(message.params);
+ final params = message.params != null
+ ? jsonHandler.convertParams(message.params)
+ : null as P;
return handle(params, token);
}
}
diff --git a/pkg/analysis_server/lib/src/lsp/source_edits.dart b/pkg/analysis_server/lib/src/lsp/source_edits.dart
index cb8fe6f..39c3cf2 100644
--- a/pkg/analysis_server/lib/src/lsp/source_edits.dart
+++ b/pkg/analysis_server/lib/src/lsp/source_edits.dart
@@ -79,7 +79,7 @@
ErrorOr<List<TextEdit>?> generateEditsForFormatting(
ParsedUnitResult result,
- int lineLength, {
+ int? lineLength, {
Range? range,
}) {
final unformattedSource = result.content;
diff --git a/pkg/analysis_server/lib/src/services/pub/pub_package_service.dart b/pkg/analysis_server/lib/src/services/pub/pub_package_service.dart
index 815711f..7d7ebbe 100644
--- a/pkg/analysis_server/lib/src/services/pub/pub_package_service.dart
+++ b/pkg/analysis_server/lib/src/services/pub/pub_package_service.dart
@@ -65,7 +65,7 @@
}
final packagesJson = json['packages'];
- if (packagesJson is! List<Object>) {
+ if (packagesJson is! List<Object?>) {
return null;
}
diff --git a/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart b/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
index c134d20..3e5300d 100644
--- a/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
+++ b/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
@@ -194,7 +194,7 @@
void _writeCanParseMethod(IndentableStringBuffer buffer, Interface interface) {
buffer
..writeIndentedln(
- 'static bool canParse(Object obj, LspJsonReporter reporter) {')
+ 'static bool canParse(Object? obj, LspJsonReporter reporter) {')
..indent()
..writeIndentedln('if (obj is Map<String, dynamic>) {')
..indent();
diff --git a/pkg/analysis_server/tool/lsp_spec/typescript.dart b/pkg/analysis_server/tool/lsp_spec/typescript.dart
index 7d36548..f857a6a 100644
--- a/pkg/analysis_server/tool/lsp_spec/typescript.dart
+++ b/pkg/analysis_server/tool/lsp_spec/typescript.dart
@@ -125,6 +125,9 @@
'ProgressParams': {
'value': 'object',
},
+ 'SemanticTokens': {
+ 'data': 'int[]',
+ },
'ServerCapabilities': {
'changeNotifications': 'bool',
},
diff --git a/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart b/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
index 5c9065e..96f7c88 100644
--- a/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
+++ b/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
@@ -672,7 +672,10 @@
if (improveTypes) {
final improvedTypeName = getImprovedType(containerName, fieldName);
if (improvedTypeName != null) {
- type = Type.identifier(improvedTypeName);
+ type = improvedTypeName.endsWith('[]')
+ ? ArrayType(Type.identifier(
+ improvedTypeName.substring(0, improvedTypeName.length - 2)))
+ : Type.identifier(improvedTypeName);
}
}
return type;