in Dot Net by
Disposable ref structs in C#

▼ Show 1 Answer

0 votes

struct declared with the ref modifier may not implement any interfaces and so can't implement IDisposable. Therefore, to enable a ref struct to be disposed, it must have an accessible void Dispose() method. This feature also applies to readonly ref struct declarations.

Learn More with Madanswer

Related questions

0 votes
0 votes
asked Dec 8, 2019 in Dot Net by Sinaya
0 votes