Closed skx closed 1 year ago
When a hash is created we populate the keys as expected, but we set the value to "readExpression..".
i.e. Hash values are not evaluated at creation time. Instead when a hash is returned as an object, via "eval" the values are evaluated then.
At the time this made sense because readExpression doesn't have access to the environment, nor does it keep track of the state of macros.
The code as-is is fine, but it requires evaluations when arrays are passed around which is gonna slow things down.
When a hash is created we populate the keys as expected, but we set the value to "readExpression..".
i.e. Hash values are not evaluated at creation time. Instead when a hash is returned as an object, via "eval" the values are evaluated then.
At the time this made sense because readExpression doesn't have access to the environment, nor does it keep track of the state of macros.
The code as-is is fine, but it requires evaluations when arrays are passed around which is gonna slow things down.