On 01/12/2020 14.58, Stefano Zacchiroli wrote:
Now the problem lies in programmatically editing *concrete* syntax, which is a complicated problem in general, due to the amount of information that parsers tend to throw away when converting to ASTs. So, Martin, everything the new Beancount parsers manage to keep (locations, comments, etc.) would be definitely welcome in this respect.
+1
Another ingredient that would help is a very-opinionated, fully-automated formatter for Beancount syntax, similar to what Black[1] is to Python. With something like that an hypothetical "sed" equivalent for Beancount syntax would be able to worry less about getting right details such as spacing, indentation, etc. --- it will just have to pipe its output to bean-format(-ng) and be done with it. (But of course this is assuming that nothing is lost in the concrete syntax -> AST translation, and most notably comments.)
+1
--
Rudd-O
http://rudd-o.com/
--
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 view this discussion on the web visit
https://groups.google.com/d/msgid/beancount/0a9a6e2a-fb62-dbc3-e990-0fcbcadbc798%40rudd-o.com.
OpenPGP_0x5C06F67A8BDEBA09_and_old_rev.asc
Description: application/pgp-keys
OpenPGP_signature
Description: OpenPGP digital signature
