Constructors with std::initializer_list

There is a constructor for State which takes an initializer_list as argument, allowing you to do things like

State s {1,0,0,1,2,2,0}; // creates the state |1001220>
danceq::internal::State::State(const std::initializer_list<IntType> &state_list)

Constructor from std::initializer_list<IntType>.

Initializes a State instance from a braced initializer list of the site states: \(\vert \sigma_i\rangle = \textbf{state_list}[i]\). Usage:

State s {0,1,1,0,1}; // creates state |01101>.

Parameters:

state_list – braced initializer list