Zulip Chat Archive
Stream: metaprogramming / tactics
Topic: Custom Deriving for Serialization Library
Oliver Dressler (Jul 21 2025 at 12:36):
I have been working on a serialization library which should support many custom structures.
Lean Metaprogramming is not my specialty, and I have arrived at this code for deriving after lots of trial and error:
https://github.com/oOo0oOo/LeanSerial/blob/main/LeanSerial/Derive.lean
(Sorry, I can't paste the code directly as the 300 LOC are too long)
My questions are:
- Is this code brittle and likely to break in practice?
- Which reasonable extensions are missing to support more structures?
Thanks for your support!
Last updated: Dec 20 2025 at 21:32 UTC