Bitwise operation on void* in C#

Posted by code poet on Stack Overflow See other posts from Stack Overflow or by code poet
Published on 2010-05-16T07:05:23Z Indexed on 2010/05/16 7:10 UTC
Read the original article Hit count: 545

Filed under:
|
|

So I am Reflector-ing some framework 2.0 code and end up with the following deconstruction

fixed (void* voidRef3 = ((void*) & _someMember))
{
...
}

This won't compile due to 'The right hand side of a fixed statement assignment may not be a cast expression'

I understand that Reflector can only approximate and generally I can see a clear path but this is a bit outside my experience.

Question: what is Reflector trying to describe to me?

Update:

Am also seeing the following

fixed (IntPtr* ptrRef3 = ((IntPtr*) & this._someMember))

© Stack Overflow or respective owner

Related posts about c#

Related posts about bitwise