El 06/09/2025 a las 11:40, Joaquin M López Muñoz escribió:
El 06/09/2025 a las 11:12, Joaquin M López Muñoz escribió:
El 06/09/2025 a las 1:50, mail--- via Boost-users escribió:
Consider the following struct:

[...]

Is there a better way of doing this that (1) does not require the creation of an object at compile-time and/or (2) is more efficient to compile?
_______________________________________________

Something like this (fails with Clang and I haven't tried with VS):

[...]

Fails in Clang because CE's latest version of Boost is 1.87: it works with Boost 1.89.

Using boost::pfr::names_as_array:

https://godbolt.org/z/er3P8sYdf

Joaquín M López Muñoz


_______________________________________________
Boost-users mailing list -- boost-users@lists.boost.org
To unsubscribe send an email to boost-users-le...@lists.boost.org
https://lists.boost.org/mailman3/lists/boost-users.lists.boost.org/
Archived at: https://lists.boost.org/archives/list/boost-users@lists.boost.org/message/HQF6YAIP2MOJBYT3SQGCFZDOS4OYMHAS/

Reply via email to