#[BUG] Getting Memory leak in just 4 lines of code,

1 messages · Page 1 of 1 (latest)

rare moat
#

The Code to produce

`
using Unity.Entities;
using UnityEngine;

public partial class TestSystem : SystemBase {
protected override void OnUpdate() {
}
}

public class Test : MonoBehaviour
{
World world;
TestSystem testSystem;

// Start is called once before the first execution of Update after the MonoBehaviour is created
void Start()
{
    world = new World("TestWorld");
    testSystem = (TestSystem)world.GetOrCreateSystemManaged(typeof(TestSystem));
}

// Update is called once per frame
void Update()
{
    
}

private void OnDestroy() {
    world.DestroySystemManaged(testSystem);

    world.Dispose();
}

}

`

#

I have disabled unity ecs bootstrapping,