Search Issue Tracker
Won't Fix
Votes
0
Found in
2017.4.0f1
2017.4.11f1
2018.3.0a1
2019.1.0a1
2019.2.0a1
Issue ID
1131564
Regression
No
Visual Studio debugger reports variables with same name in Coroutine as null
How to reproduce:
1. Open the attached project ("case_1131564-VisualStudioDebuggerIncorrectNull.zip")
2. Open the "TestScript" and start debugging it
3. Set a breakpoint in TestIEnumerator() and check the values of variables "g" and "mc"
Expected result: "g" correctly shows its value as Game Object "first node" and "mc" shows its value as "MeshCollider"
Actual result: "g" and "mc" values are returned as null
Reproduced in: 2019.2.0a6, 2019.1.0b5, 2018.3.7f1, 2017.4.22f1
Note: only reproduces if there's a "yield return null" statement in the 2nd block-scope and the two variables in different scopes have the same name
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
- Crash on GUIManager::DoGUIEvent when focusing on the Game view window on a specific project
- Asset creation in the Project Browser is not always undone/inconsistent when the undo shortcut is pressed right after creating an asset
- JobTempAlloc memory leak warning is thrown when the Player is shut down
- Graphics State Collection warm-up does not work when using with Addressables Shaders
- "Baked Shadow Radius" field is visible but inactive when when the Shadow Type is set to "Hard Shadows" under the Light Component
Resolution Note:
This is only an issue when using the old scripting runtime, likely due to a bug in the Mono C# compiler. The legacy scripting runtime has been deprecated at 2018.3 and is being removed for 2019.2. Please use the new scripting runtime which uses the Roslyn C# compiler to avoid this issue.