When invoking class constructor ensure class is initialized (#40293)
authorDavid Wrighton <davidwr@microsoft.com>
Wed, 5 Aug 2020 16:10:15 +0000 (09:10 -0700)
committerGitHub <noreply@github.com>
Wed, 5 Aug 2020 16:10:15 +0000 (09:10 -0700)
commitdd05d4757795224e7ffd996c030a7080001a03a8
tree8b09d273cd09804b0375141ed73af2fe631ee68a
parent06963eaedfe666c087a9fabb89b3f4bca57634c7
When invoking class constructor ensure class is initialized (#40293)

When invoking the class constructor method via reflection invoke, ensure that the class constructor is run via the standard run class constructor pathway instead of running it explicitly. Do the same for module constructors.
src/coreclr/src/System.Private.CoreLib/src/System/Reflection/INVOCATION_FLAGS.cs
src/coreclr/src/System.Private.CoreLib/src/System/Reflection/RuntimeConstructorInfo.cs
src/libraries/System.Reflection/tests/ConstructorInfoTests.cs