C2 forum

General Category => Ideas => Topic started by: lerno on December 17, 2020, 02:54:38 AM

Title: Distinct types
Post by: lerno on December 17, 2020, 02:54:38 AM
An interesting feature in Odin is that of "distinct" types. That is, it acts like you actually created a completely new type, not a typedef alias. That way you can for example have a "UserId" type which is an int underneath but typechecks as if it was another type.