|
Boost : |
From: Andrzej Krzemienski (akrzemi1_at_[hidden])
Date: 2021-03-08 11:20:30
Hi Everyone,
First of all, I wanted to thank Peter for writing and sharing this library.
A number of people already indicated it is useful, and I also have use
cases that would be addressed by this library.
I would lie to clarify if my understanding of the scope of this library is
correct. From the discussion so far, I understood that the goal is to
provide a low-level minimum building block that enables writing more
elaborate libraries for providing type introspection. The library gives me
the following guarantee: if a user used macro BOOST_DESCRIBE_STRUCT for
some type T (and there are no ODR violations) than I can use
`boost::describe::members` to see what those members are: their name, their
type, and a pointer.
If I want to use this data in a convenient way, I have to use another
library atop of Boost.Describe. For instance, when I need to observe struct
X as a tuple of references, I will write my own library, which:
1. Checks if Boost.PFR can figure it out automagically. If so, use this
magic
2. If not, resort to Boost.Describe, and based on its interface, form a
tuple of references.
Did I capture it correctly? In that case, requesting high-level features in
Boost.Describe is against its design goals. It is a low-level piece, not
necessarily to be used directly.
Regard,
&rzej;
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk