Use std::bitset, allowing for an arbitrary number of components.