Why does Int64.MaxValue return Long?

Wow, ironic , during the game today I wondered if there was any way to increase Int64.MaxValue and had just founded Int64.MaxValue not Int64, but Long.

Why is this so, does it mean, if I store as Int64 myInt = Int64.MaxValue;, than myInt will still be Int or it will become long, what is the purpose of the Long storage instead of Int64in this field.

+5
source share
6 answers

Because Int64 and long are of the same type.

Int64 = long    
Int32 = int    
Int16 = short
+16
source

long - Int64. . .

+3

:

struct, :

long System.Int64.

. 3.4.4.

4.1.4:

# , . , System, .

Reserved word Aliased type
long          System.Int64
+3

Int64 :

        Type t1 = typeof(Int64);
        Type t2 = typeof(long);
        bool same = t1.Equals(t2);  // true

MSDN:

http://msdn.microsoft.com/en-us/library/ya5y69ds.aspx

+2

Int16, Int32 Int64, short, int long . , - , .

0
source

All Articles