Tutorial by Examples

An enumerated type is a type that can hold one of a finite list of possible values. In Julia, enumerated types are typically called "enum types". For instance, one could use enum types to describe the seven days of the week, the twelve months of the year, the four suits of a standard 52-ca...
Although the @enum macro is quite useful for most use cases, it can be excessive in some use cases. Disadvantages of @enum include: It creates a new type It is a little harder to extend It comes with functionality such as conversion, enumeration, and comparison, which may be superfluous in some...

Page 1 of 1