Algebraic Data Types 2019-10-18
I updated a bunch of the code for Python 3.8. The code is a lot nicer now. Now I just need to wait for the tools to catch up, because it seems like everything I've tried has managed to be at least a little buggy.
Let's see what order I have to work on things...
- Design new placeholder-related behavior
- Create alternative non-data descriptor classes for class- and static- methods
- Collapse function and method back together, if possible
- Use a single factory function in the external interface
- Improve type annotations
- Mutation testing
Tomorrow I'll try prototyping backends for the placeholder stuff. The basic idea is that if there's no placeholder, then it can act like a totally normal function, but if there is a placeholder, anywhere, then it needs to perform single-dispatch. This should mean that the registration concept becomes unnecessary, and the same idea can be accomplished via a cache.
Once all that is done, it's time to check the helper-for-enums idea out again, and then I think the natural place to go is to start trying to port Dennis from Coconut to Structured Data.
I can't be awake any longer, again. Good night.