Seth Reno
Seth Reno

Reputation: 5450

What is the official name for this syntax feature?

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.

Upvotes: 3

Views: 157

Answers (3)

Mark Byers
Mark Byers

Reputation: 838974

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

Upvotes: 3

Mariano Desanze
Mariano Desanze

Reputation: 8163

According to MSDN in C# are called: Type suffix

Upvotes: 2

Fredrik Mörk
Fredrik Mörk

Reputation: 158379

It's called a type suffix.

Upvotes: 5

Related Questions