Highly subjective but to me, mySpecialName as SomeType
looks semantically backwards and somewhat like a type cast[1]. The other way around, given SomeType as mySpecialName
, has some history in at least the form of SQL-aliases. It also flows more naturally from the fact that the required bit — the type — comes first, followed by the bit that can be left out.
[1] https://kotlinlang.org/docs/reference/typecasts.html#unsafe-cast-operator
[2] https://www.w3schools.com/sql/sql_alias.asp