Closed matjin closed 1 year ago
Overall it looks OK. I would suggest to create a unit test for this PR, with a resource in custom type allocated in the using statement.
Overall it looks OK. I would suggest to create a unit test for this PR, with a resource in custom type allocated in the using statement.
As discussed offline, I will go back and redo the test cases: the "Examples" solution should be our validation set for all of our pulse-based analysis.
I have already prepared the test case I will add later.
This work will happen around when we go back and fix the nested using/translation of ldftn.
The "using" construct in C# yields bytecode that invokes IDisposable.Dispose() rather than the instance's corresponding method. This can create issues when this method is for a user-defined IDisposable class, with a corresponding custom Dispose method, as then the spec for this method would fail to be applied. To fix this, we make sure that in such instances we invoke the instance's Dispose method.