I was wondering why do we use integers to get addresses in memory while memory addresses can only be positive? Why don't we use unsigned integers?
For example:
in C#, why do we have IntPtr, why not UIntPtr?
Arrays also have a limitation of Int32.Max. Still, why not unsigned since index can only be >= 0?
Also, in C++, a lot of codes assign a pointer address to ints, and not uints, is there a reason behind it? Is it bad practice?
Thank you!