biocpp / biocpp-io

BioC++ Input/Output library
https://biocpp.github.io
BSD 3-Clause "New" or "Revised" License
8 stars 5 forks source link

field_types check #16

Closed h-2 closed 2 years ago

h-2 commented 2 years ago

@smehringer This is how we can enforce the requirements on the field_types and other members of the options.

Since concept checks are lazy-evaluated when constraining something but not lazy-evaluated when in a static_assert or if constexpr, I had to add some metaprogramming voodoo. The overloaded template is really useful in general though, I am surprised we didn't have that in SeqAn3, yet. (or maybe I was just too stupid to find it)

If you have any questions, please let me know!

h-2 commented 2 years ago

fixed the GCC10 problems

h-2 commented 2 years ago

Currently, the checks have no measurable impact on compile-times.