Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
std::vector<T> foo(100)使用 的默认值初始化每个元素T。做boost::multi_array<T, 2> foo(boost::extents[10][10])同样的事情吗?
std::vector<T> foo(100)
T
boost::multi_array<T, 2> foo(boost::extents[10][10])
确实如此,std::allocator::construct()默认使用。
std::allocator::construct()