Skip to content

Commit 39ff937

Browse files
rmacnak-googlecommit-bot@chromium.org
authored andcommitted
[vm] Rename _LocalXMirror to _XMirror.
Remote mirrors ended up being implemented as the service protocol instead of a Dart API. Change-Id: I03b6c92d6acdde28e7b55044d98e075f5a1fe57e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/109321 Commit-Queue: Ryan Macnak <[email protected]> Reviewed-by: Siva Annamalai <[email protected]>
1 parent bcca3c4 commit 39ff937

File tree

5 files changed

+94
-96
lines changed

5 files changed

+94
-96
lines changed

runtime/lib/mirrors.cc

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ static RawInstance* CreateParameterMirrorList(const Function& func,
177177
args.SetAt(6, is_final);
178178
args.SetAt(7, default_value);
179179
args.SetAt(8, metadata);
180-
param = CreateMirror(Symbols::_LocalParameterMirror(), args);
180+
param = CreateMirror(Symbols::_ParameterMirror(), args);
181181
results.SetAt(i, param);
182182
}
183183
results.MakeImmutable();
@@ -190,7 +190,7 @@ static RawInstance* CreateTypeVariableMirror(const TypeParameter& param,
190190
args.SetAt(0, param);
191191
args.SetAt(1, String::Handle(param.name()));
192192
args.SetAt(2, owner_mirror);
193-
return CreateMirror(Symbols::_LocalTypeVariableMirror(), args);
193+
return CreateMirror(Symbols::_TypeVariableMirror(), args);
194194
}
195195

196196
// We create a list in native code and let Dart code create the type mirror
@@ -225,7 +225,7 @@ static RawInstance* CreateTypedefMirror(const Class& cls,
225225
args.SetAt(3, Bool::Get(cls.IsGeneric()));
226226
args.SetAt(4, cls.IsGeneric() ? is_declaration : Bool::False());
227227
args.SetAt(5, owner_mirror);
228-
return CreateMirror(Symbols::_LocalTypedefMirror(), args);
228+
return CreateMirror(Symbols::_TypedefMirror(), args);
229229
}
230230

231231
static RawInstance* CreateFunctionTypeMirror(const AbstractType& type) {
@@ -236,7 +236,7 @@ static RawInstance* CreateFunctionTypeMirror(const AbstractType& type) {
236236
args.SetAt(0, MirrorReference::Handle(MirrorReference::New(cls)));
237237
args.SetAt(1, MirrorReference::Handle(MirrorReference::New(func)));
238238
args.SetAt(2, type);
239-
return CreateMirror(Symbols::_LocalFunctionTypeMirror(), args);
239+
return CreateMirror(Symbols::_FunctionTypeMirror(), args);
240240
}
241241

242242
static RawInstance* CreateMethodMirror(const Function& func,
@@ -276,7 +276,7 @@ static RawInstance* CreateMethodMirror(const Function& func,
276276
kind_flags |= (static_cast<intptr_t>(is_synthetic) << Mirrors::kSynthetic);
277277
args.SetAt(5, Smi::Handle(Smi::New(kind_flags)));
278278

279-
return CreateMirror(Symbols::_LocalMethodMirror(), args);
279+
return CreateMirror(Symbols::_MethodMirror(), args);
280280
}
281281

282282
static RawInstance* CreateVariableMirror(const Field& field,
@@ -295,7 +295,7 @@ static RawInstance* CreateVariableMirror(const Field& field,
295295
args.SetAt(5, Bool::Get(field.is_final()));
296296
args.SetAt(6, Bool::Get(field.is_const()));
297297

298-
return CreateMirror(Symbols::_LocalVariableMirror(), args);
298+
return CreateMirror(Symbols::_VariableMirror(), args);
299299
}
300300

301301
static RawInstance* CreateClassMirror(const Class& cls,
@@ -326,7 +326,7 @@ static RawInstance* CreateClassMirror(const Class& cls,
326326
args.SetAt(6, Bool::Get(cls.is_transformed_mixin_application()));
327327
args.SetAt(7, cls.NumTypeParameters() == 0 ? Bool::False() : is_declaration);
328328
args.SetAt(8, Bool::Get(cls.is_enum_class()));
329-
return CreateMirror(Symbols::_LocalClassMirror(), args);
329+
return CreateMirror(Symbols::_ClassMirror(), args);
330330
}
331331

332332
static bool IsCensoredLibrary(const String& url) {
@@ -360,15 +360,15 @@ static RawInstance* CreateLibraryMirror(Thread* thread, const Library& lib) {
360360
return Instance::null();
361361
}
362362
args.SetAt(2, str);
363-
return CreateMirror(Symbols::_LocalLibraryMirror(), args);
363+
return CreateMirror(Symbols::_LibraryMirror(), args);
364364
}
365365

366366
static RawInstance* CreateCombinatorMirror(const Object& identifiers,
367367
bool is_show) {
368368
const Array& args = Array::Handle(Array::New(2));
369369
args.SetAt(0, identifiers);
370370
args.SetAt(1, Bool::Get(is_show));
371-
return CreateMirror(Symbols::_LocalCombinatorMirror(), args);
371+
return CreateMirror(Symbols::_CombinatorMirror(), args);
372372
}
373373

374374
static RawInstance* CreateLibraryDependencyMirror(Thread* thread,
@@ -419,7 +419,7 @@ static RawInstance* CreateLibraryDependencyMirror(Thread* thread,
419419
args.SetAt(4, Bool::Get(is_import));
420420
args.SetAt(5, Bool::Get(is_deferred));
421421
args.SetAt(6, metadata);
422-
return CreateMirror(Symbols::_LocalLibraryDependencyMirror(), args);
422+
return CreateMirror(Symbols::_LibraryDependencyMirror(), args);
423423
}
424424

425425
static RawInstance* CreateLibraryDependencyMirror(Thread* thread,
@@ -644,7 +644,7 @@ static RawInstance* CreateIsolateMirror() {
644644
const Array& args = Array::Handle(Array::New(2));
645645
args.SetAt(0, debug_name);
646646
args.SetAt(1, root_library_mirror);
647-
return CreateMirror(Symbols::_LocalIsolateMirror(), args);
647+
return CreateMirror(Symbols::_IsolateMirror(), args);
648648
}
649649

650650
static void VerifyMethodKindShifts() {
@@ -653,7 +653,7 @@ static void VerifyMethodKindShifts() {
653653
Zone* zone = thread->zone();
654654
const Library& lib = Library::Handle(zone, Library::MirrorsLibrary());
655655
const Class& cls = Class::Handle(
656-
zone, lib.LookupClassAllowPrivate(Symbols::_LocalMethodMirror()));
656+
zone, lib.LookupClassAllowPrivate(Symbols::_MethodMirror()));
657657
Error& error = Error::Handle(zone);
658658
error ^= cls.EnsureIsFinalized(thread);
659659
ASSERT(error.IsNull());

0 commit comments

Comments
 (0)