prog.cpp: In function ‘int main()’:
prog.cpp:8:25: error: invalid initialization of non-const reference of type ‘bool&’ from an rvalue of type ‘bool’
bool &some_bool = vec[2];
~~~~~^
In file included from /usr/include/c++/6/vector:65:0,
from prog.cpp:2:
/usr/include/c++/6/bits/stl_bvector.h:80:5: note: after user-defined conversion: std::_Bit_reference::operator bool() const
operator bool() const _GLIBCXX_NOEXCEPT
^~~~~~~~