Search Issue Tracker
Fixed in 2020.2.X
Fixed in 2020.1.X
Votes
0
Found in
2020.1.0b2
2020.1.0b14
2020.2.0a3
Issue ID
1263916
Regression
Yes
[IL2CPP] Managed Code Stripping strips a parameterless constructor from a managed dll when using IL2CPP Scripting Backend
Reproduction steps:
1. Open the attached "1263916 repro" project
2. Open Build Settings from File > Build Settings
3. Make sure that "Development Build" is checked
4. Build and Run the project
Expected result: no error is thrown and the "double_this_int" method returns 26
Actual result: MissingMethodException is thrown
Reproducible with: 2020.1.0b2, 2020.1.1f1, 2020.2.0a3, 2020.2.0a19
Not reproducible with: 2018.4.25f1, 2019.4.5f1, 2020.1.0b1, 2020.2.0a2
Notes:
-This doesn't reproduce with any Managed Stripping level on Mono Scripting Backend
-The 3rd step isn't mandatory and doesn't affect the outcome, it's there only to illustrate the issue more easily
-The full error is:
MissingMethodException: A parameterless constructor is required for type 'ManagedPlugin.Helper/Thing'.
at ManagedPlugin.Helper.double_this_int (System.Int32 x) [0x00000] in <00000000000000000000000000000000>:0
at Test.Start () [0x00000] in <00000000000000000000000000000000>:0
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- “[Worker0] Could not generate preview image“ error when opening macOS native plugin in the Inspector with Architecture to build for set to ARM 64-bit
- [iOS] Application.absoluteURL is empty on Awake/Start when opening via deep link with Splash Screen disabled
- Crash on MemoryManager::Deallocate when rapidly calling Addressables.LoadAssetAsync
- Crash on physx::shdfnd::atomicIncrement when adjusting values on a character controller component after entering Play mode in Prefab edit mode
- [Rendering Debugger] [NewInputSystem] Debug Overlays in Play mode throws InvalidOperationException when using New Input System
Resolution Note (fix version 2020.2):
Fixed in 2020.2.0b2
Resolution Note (fix version 2020.1):
Fixed in 2020.1.11f1