You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sorry to reply so late... You're right, the value should be pinned, but the struct is designed for VB, which doesn't have the equivalent grammer to ref variables and ref fields in C#. Anyway, I'll add the warning to the document, thanks!
That code allows to store ref inside struct. May be usefull for ECS systems in gamedev. I.e. memory will not be ever reclaimed from lists but loop onto next frame.
ClassLibrary/src/Berrysoft.Unsafe/ByReference.cs
Line 22 in 9f6eca4
To avoid GC change location and invalidate pointer. I guess.
The text was updated successfully, but these errors were encountered: