Currently, x4::char_set internally uses x4::detail::basic_chset which holds the internal buffer by x4::detail::char_range_run that uses std::vector.
In theory, this internal buffer can be totally constexpr if we do the parser construction in two phases and statically determine the maximum buffer amount in consteval preparation step (note: NOT constexpr). We can use std::inplace_vector (C++26; polyfill needed in iris-cpp/iris) for implementation details.
Currently,
x4::char_setinternally usesx4::detail::basic_chsetwhich holds the internal buffer byx4::detail::char_range_runthat usesstd::vector.In theory, this internal buffer can be totally constexpr if we do the parser construction in two phases and statically determine the maximum buffer amount in
constevalpreparation step (note: NOTconstexpr). We can usestd::inplace_vector(C++26; polyfill needed iniris-cpp/iris) for implementation details.