1 // Copyright (C) 2019 T. Zachary Laine 2 // 3 // Distributed under the Boost Software License, Version 1.0. (See 4 // accompanying file LICENSE_1_0.txt or copy at 5 // http://www.boost.org/LICENSE_1_0.txt) 6 #include "static_vector.hpp" 7 8 main()9int main() 10 { 11 //[ static_vector_usage 12 static_vector<int, 128> vec; 13 vec.push_back(42); 14 vec.push_back(13); 15 assert(vec[0] == 42); 16 assert(vec[1] == 13); 17 assert(vec.size() == 2u); 18 19 vec.erase(vec.end() - 1); 20 static_vector<int, 128> tmp({42}); 21 assert(vec == (static_vector<int, 128>({42}))); 22 //] 23 } 24