vector<bool>和vector<Class T>不同。给我惹了大麻烦
The references to elements of a bool vector returned by the vector members are not references to bool objects, but a special member type which is a...
Although the standard lists vector in Clause 23, vector is not a container and vector::iterator is not a random-access iterator (or even a forward or bidirectional iterator either, for that matter). This has already broken user code in the field in mysterious ways.