Why can't we do IntPtr and UIntPtr arithmetic in C#?
It's a simple-looking question: Given that native-sized integers are the best for arithmetic, why doesn't C# (or any other .NET language) support arithmetic with the native-sized IntPtr and UIntPtr ? Ideally, you'd be able to write code like: for (IntPtr i = 1; i < arr.Length; i += 2) //arr.Length should also return IntPtr { arr[i - 1] += arr[i]; //something random like this } so that it would work on both 32-bit and 64-bit platforms. (Currently, you have to use long .) Edit: I'm not using these as pointers (the word "pointer" wasn't even mentioned)! They can be just treated as the C#