Exactly, this "traditional" right between quotation marks. The way you call traditional comes from the C style, which is considered bad by many.
Complicates compiler because it generates context for parser, hinders the inference of types, requires a keyword before the statement when does not mean the type (although Kotlin erred in this, in my opinion*).
Many people also consider it more readable so it gets more fluid. The variable name is more important than its type. In fact in types like big names until you find the variable name is a sadness:
val shapeInfo: HashMap[Shape, (String, String)] = makeInfo()
val HashMap[Shape, (String, String)] shapeInfo := makeInfo()
I put in the Github for future reference.
Which you find the variable name more easily?
*I’d prefer something like this:
variavel := 1
constante ::= 1
variavel : Int
Easier to find the name, right? Always in column 0.
Identifiers are very important in the code, giving visibility to them is critical.
I don’t think it’s a revealing motive or anything like that. I believe it’s a semantic differential only. As in php for example we declare variables with the $ in front and changes absolutely nothing. Only semantics rs.
– Bsalvo