Howdy folks!
I'm looking to release the next version of Lowerdash soon. One of the new features is string members in modules, and I'm curious what syntax the community likes best.
Currently users can declare an untyped numerical variable with:
MEM memberAnd access it with:
_(instance,"member")Option 1: What type is this again? MEM declarations that end with a $ will be added to the symbol table as strings
MEM string$These members can then be accessed with:
_(instance,"string")Pro * Single way to access everything module related Con * The type is not obvious when you access the variable. Option 2: Magical special case Introduce MEM$ declarations to add to the symbol table as strings
MEM$ stringThese members can then be accessed with:
_$(instance,"string")Pros * Type is apparent * Can optimize lookup time Cons * Janky syntax just for strings * Function AND Numbers are still accessed from _(). Should there be a _%()? Poll Reply with a number to vote! 1 - What type is this again? 2 - Magical special case 3 - A better suggestion