Search Issue Tracker
Duplicate
Votes
0
Found in
2017.4.0f1
2018.3.0a1
2018.3.0f2
2019.1.0a1
Issue ID
1126214
Regression
No
Memory Leak in MonoScript is caused by creating a nested Class that is inside of a Namespace
How to reproduce:
1. Download the user-submitted script(MemoryTest.cs)
2. Create a new Unity project
3. Import and attach the script onto any GameObject
4. Enter Play Mode
5. Open Window > Analysis > Profiler and select the Detailed Memory profiler
6. Take a sample from the Editor and see Scene Memory > MonoScript
Expected result: no memory leak occurs
Actual result: a memory leak occurs
Reproducible with: 2017.4.22f1, 2018.3.7f1, 2019.1.0a7
Not reproducible with: 2019.1.0a8, 2019.1.0b5, 2019.2.0a7
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
- Some UXML Template Asset foldouts appear enabled when all fields inside are disabled
- URP Terrain Demo crash on burst_signal_handler after Generating lighting
- Project window button icons are poorly visible and their shades differ in Light theme
- GC.Alloc called by HDRenderPipeline.LensFlareMergeOcclusionDataDrivenPass() when playing the default HDRP Sample Template project
- Automatic LOD fails and SRP Batcher incompatibility occurs when using spline-based quad-topology meshes
This is a duplicate of issue #1085304