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

Unified Diff: runtime/lib/mirrors.cc

Issue 58183003: Implement VariableMirror.isConst in the VM and ParameterMirror.isConst in dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 | runtime/lib/mirrors_impl.dart » ('j') | tests/lib/mirrors/parameter_is_const_test.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/mirrors.cc
diff --git a/runtime/lib/mirrors.cc b/runtime/lib/mirrors.cc
index 22b2d47fa4b2ea1c81d9c35b3526026b3b24293d..d66e05d467ffc8714717b494d8da63b3a94a9fc6 100644
--- a/runtime/lib/mirrors.cc
+++ b/runtime/lib/mirrors.cc
@@ -300,13 +300,14 @@ static RawInstance* CreateVariableMirror(const Field& field,
const String& name = String::Handle(field.name());
- const Array& args = Array::Handle(Array::New(6));
+ const Array& args = Array::Handle(Array::New(7));
args.SetAt(0, field_ref);
args.SetAt(1, name);
args.SetAt(2, owner_mirror);
args.SetAt(3, Object::null_instance()); // Null for type.
args.SetAt(4, Bool::Get(field.is_static()));
args.SetAt(5, Bool::Get(field.is_final()));
+ args.SetAt(6, Bool::Get(field.is_const()));
return CreateMirror(Symbols::_LocalVariableMirrorImpl(), args);
}
« no previous file with comments | « no previous file | runtime/lib/mirrors_impl.dart » ('j') | tests/lib/mirrors/parameter_is_const_test.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698