*TL/DR: what's the purpose of new_directive() wrapper around NamedTuple()?*
I've been following Beancount for a while, and I wanted to fork the project and make some modifications for my own use and maybe contribute back to the project at some point. But before that I want to get a good understanding of the source code. I was going through the basic data structures, and I'm trying to understand the *new_directive *factory. In beancount.core some classes (e.g. Posting) are created via a *NamedTuple()*, while others (e.g. Transaction) are created via *new_directive()*. *new_directive()* itself is a thin wrapper around *NamedTuple()* anyway. So I would like to know what is the rationale for using one over the other, or for new_directive() existence in general? -- You received this message because you are subscribed to the Google Groups "Beancount" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beancount/81671f79-c6e0-4176-8175-d2647032d91d%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
