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

Unified Diff: pkg/dev_compiler/tool/input_sdk/private/js_mirrors.dart

Issue 2861503002: fix #29530, field metadata generation (Closed)
Patch Set: wip Created 3 years, 8 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/dev_compiler/tool/input_sdk/private/js_mirrors.dart
diff --git a/pkg/dev_compiler/tool/input_sdk/private/js_mirrors.dart b/pkg/dev_compiler/tool/input_sdk/private/js_mirrors.dart
index 8df816e173d082a46600849502fb860835541284..a5e272012403dcdcd91dfb913032e970e698f610 100644
--- a/pkg/dev_compiler/tool/input_sdk/private/js_mirrors.dart
+++ b/pkg/dev_compiler/tool/input_sdk/private/js_mirrors.dart
@@ -541,8 +541,8 @@ class JsVariableMirror extends JsMirror implements VariableMirror {
: _symbol = symbol,
_name = getName(symbol),
type = reflectType(t),
- metadata =
- new List<InstanceMirror>.unmodifiable(annotations.map(reflect));
+ metadata = new List<InstanceMirror>.unmodifiable(
+ annotations?.map(reflect) ?? []);
JsVariableMirror._fromField(Symbol symbol, fieldInfo)
: this._(symbol, _wrap(JS('', '#.type', fieldInfo)),
« no previous file with comments | « pkg/dev_compiler/lib/src/compiler/code_generator.dart ('k') | tests/lib_strong/mirrors/field_metadata2_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698