Is it guaranteed for GcHandle.ToIntPtr not to return zero for non-null values? #96958
-
I could not find documentation that express this but is it guaranteed? |
Beta Was this translation helpful? Give feedback.
Answered by
huoyaoyuan
Jan 15, 2024
Replies: 1 comment 2 replies
-
It's somehow a common contract of "handle": 0 value always means equivalent of null. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In my mind, it's too common beyond GCHandle. It's applicable for any handle.