Closed DCNick3 closed 1 year ago
There is not natively; your best bet is to use the forward_attrs
to collect all the ones you're interested in, and to then use and_then
or map
to take apart the attrs. derive_builder
has some examples of this in its source code.
Is it possible to parse "naked" attributes, like the ones you can find in
thiserror
? They do not have a common attribute with fields inside them being the meaning (like in darling), but the mere presence of that attribute is what conveys the information.I would like a boolean flag in the received that would be
false
for the field of the first variant andtrue
for the second one. Is it possible to achieve with darling?