[sre] FieldBuilder:RuntimeResolve shouldn't lookup by name. (Fixes #57222)
authorAleksey Kliger <aleksey@xamarin.com>
Thu, 8 Jun 2017 19:56:30 +0000 (15:56 -0400)
committerAleksey Kliger <aleksey@xamarin.com>
Thu, 8 Jun 2017 20:13:57 +0000 (16:13 -0400)
commit64d523c524d00b54088803a35cd08bb66a70f498
treebf41d824c3324baabcf16b12677a4ff3e0916c8d
parent6b1529a15c8ef9af182fcef82c327eaa966229f9
[sre] FieldBuilder:RuntimeResolve shouldn't lookup by name. (Fixes #57222)

RuntimeType:GetField (FieldInfo) looks up the field by name and attributes,
which doesn't work for SRE because it is legal to create multiple fields with
the same name and type and attributes.  So lookup using the
RuntimeFieldHandle (aka MonoClassField*) instead.
mcs/class/corlib/System.Reflection.Emit/FieldBuilder.cs