-
Notifications
You must be signed in to change notification settings - Fork 4
Description
I would suggest considering to use the Symbol type for the item labels (i.e. those that are called labels in GAMS). These should be immutable anyway, and therefore I think the symbol type would seem to fit well, and may have some performance benefits.
Quote from educative.io:
Unlike strings, symbols are immutable, which means their values cannot be changed once created. This immutability grants symbols a few advantages over strings, especially in certain programming scenarios. One significant advantage of symbol immutability is its efficiency in comparison operations. When comparing two symbols, Julia simply needs to check their memory addresses to determine if they refer to the same symbol. In contrast, comparing two strings requires examining each character in the strings until a mismatch is found or confirming that the entire strings are identical.