Em seg., 21 de set. de 2020 às 16:19, Hans Dembinski via Boost
On second thought, the Archive concept probably needs an extension to work with json::value. While writing is no problem, reading is a challenge.
From one lens, you're using json::value against json::archive. If
From the second lens, you have a problem, external archive. And here,
It depends on the lens you use. The archive concept overloads primitive types to be serializable. Other serializables are always built on top of the primitives the underlying archive has special code for. that's the case, it has special code here, so fine and everything works as has been described in previous emails. the rest of the rationale you described in your email applies. You do need extensions in a separate concept thou. If you want to control beautiful JSON serialization, you need to expose a few extensions like Bjørn has done in his serialization code. I do disagree about a few things he has done, but we can reach consensus in the future. One thing I want to develop here is integration to Boost.Hana reflection. If you have integration to Boost.Hana Struct concept, it helps a ton. First, creating new serializables will be very easy. Second, you avoid the whole "index/buffer/backtrack/lookahead" problem you guys mentioned. This won't work for push parsers, but pull parsers will benefit a lot.
Bottom line, it is not so easy as I thought.
True. I do would like to discuss this subject, but I need to organize my own thoughts first. It'd be nice if you, Mathias Gaunard, Robert Ramey, and other stakeholders could gather together to explore this topic in detail after Boost.JSON review. -- Vinícius dos Santos Oliveira https://vinipsmaker.github.io/