While working with unmanaged code in Unity and Visual Studio I noticed that VS gets confused about certain operations when debugging. For instance arithemtic on pointers to value types, like this: SomeStruct* somePointer; SomeStruct* anotherPointer = somePointer + 1; result in a pointer that is offset by 8 Byte. Similarly sizeof(SomeStruct) can't be evaluated by VS. Mind you, the code works fine, this is just a Visual Studio debugging issue. It works as expected in .net framework and .net core environments. Does anyone know a solution? It's virtually impossible to debug unsafe code in Unity like this. Tested with Unity 2018.3 (both Mono and IL2CPP backends) and Visual Studio 2017.