Closed sledorze closed 11 years ago
Can I think about this? I do agree with you especially around performance and memory usage, but the other side of the coin this is premature optimisation and I wonder how much actual runtime cost this is.
I'm more than happy to change, it just affects more code that this throughout the code base.
This is post optimisation :) The code is closed, it's a leaf and could be used a lot so impact could be huge. Also, as for that general thinking, indeed, it may also apply to the way enums are used to represent structures like tuples; using enums add some extra information which may be not necessary (simple arrays may do the trick behind the abstracts). Anyway, like Stax, expressivity is key, performance comes second but if done for free, not a bad decision IMHO. Take your time :)
"expressivity is key, performance comes second but if done for free, not a bad decision IMHO."
Think I might take that on. Cheers.
Pull this, will try to keep my open for things like this. If you spot anything else, please let me know. Cheers for this.
I stress the idea that internal implementation should be made efficient as a default while still exposing functional usage. This gives best performance without reducing composability.