views:

101

answers:

3

What is the name of the character at the end of each of these lines?

Dim _int As Integer = 1I
Dim _short As Short = 1S
Dim _long As Long = 1L
Dim _single As Single = 1.0F
Dim _double As Decimal = 1D

I've always called these "type specifiers". I assume that's incorrect as I'm unable to find the official documentation using this term. I would like to know what others are available but can't find the right term to use in my search.

+5  A: 

It's called a type suffix.

Fredrik Mörk
seems so obvious now :)
Seth Reno
http://msdn.microsoft.com/en-us/library/bfft1t3c.aspx
Jon B
Thanks @Jon, was looking for it but couldn't find it.
Fredrik Mörk
+3  A: 

According to the documentation in VB.NET they are called "literal type characters". See the section on "forced literal types".

Mark Byers
I marked this as the accepted answer because my code example was VB not C#.
Seth Reno
+2  A: 

According to MSDN in C# are called: Type suffix

Protron