I have to say I was pleased when I opened up c# to see the integer data types being Int16,Int32 and Int64
. It removed any ambiguity e.g int increasing in size with age.
What surprises me is why there isn't or doesn't seem to be Float16,Float32 and Float64
or atleast not in normal use: a quick search of MSDN refers to float64 as R8 (unmanaged type) isn't this the same as a double
My guess would be there isn't as much ambiguity in Single and Double (or even Extended(Float80) which doesn't exist in c# as far as I know, I'm not sure how this could be marshalled for that matter.) Although Decimal seems to be a Float128 and I've noted it refered to as "Extended Floating Point Precision", Should we see an Int128 to match it?
EDIT: There isn't any ambiguity at all in Single or Double (which was a guess but it appears to be true and I thought I'd add this for clarity.)
Should we expect to see this kind of naming convention?/ would you appreciate it if we did?
Or should we go one step further and have Int<N>
for arbitary number sizes? (yes I realise there are libraries out there which support this kind of thing)