fork download
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3.  
  4. template<class T, size_t N>
  5. struct StaticAllocator {
  6. using value_type = T;
  7.  
  8. StaticAllocator() noexcept {}
  9.  
  10. template<class U>
  11. StaticAllocator( const StaticAllocator<U, N>& other ) noexcept {}
  12.  
  13. T* allocate( size_t n ) noexcept
  14. {
  15. /* TBD */
  16. return nullptr;
  17. }
  18.  
  19. void deallocate( T* p, size_t n ) noexcept
  20. {
  21. /* TBD */
  22. }
  23. };
  24.  
  25. int main()
  26. {
  27. using A = StaticAllocator<int, 256>;
  28. using T = allocator_traits<A>;
  29. static_assert( is_same<T::value_type, int>::value, "" ); // ok
  30.  
  31. A a;
  32. vector<int, A> v( a );
  33. v.push_back( 42 );
  34. }
  35.  
Compilation error #stdin compilation error #stdout 0s 4360KB
stdin
Standard input is empty
compilation info
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h: In instantiation of ‘struct std::allocator_traits<StaticAllocator<int, 256ul> >’:
prog.cpp:29:29:   required from here
/usr/include/c++/6/bits/alloc_traits.h:187:7: error: static assertion failed: allocator defines rebind or is like Alloc<T, Args>
       static_assert(!is_same<rebind_alloc<value_type>, __undefined>::value,
       ^~~~~~~~~~~~~
/usr/include/c++/6/bits/alloc_traits.h: In instantiation of ‘struct std::allocator_traits<std::__undefined>’:
/usr/include/c++/6/ext/alloc_traits.h:50:10:   required from ‘struct __gnu_cxx::__alloc_traits<std::__undefined>’
/usr/include/c++/6/bits/stl_vector.h:77:9:   required from ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >’
/usr/include/c++/6/bits/stl_vector.h:214:11:   required from ‘class std::vector<int, StaticAllocator<int, 256ul> >’
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/alloc_traits.h:88:43: error: invalid use of incomplete type ‘class std::__undefined’
       typedef typename _Alloc::value_type value_type;
                                           ^~~~~~~~~~
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:95:70: error: invalid use of incomplete type ‘class std::__undefined’
       using pointer = __detected_or_t<value_type*, __pointer, _Alloc>;
                                                                      ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:105:26: error: invalid use of incomplete type ‘class std::__undefined’
      __c_pointer, _Alloc>;
                          ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:105:26: error: invalid use of incomplete type ‘class std::__undefined’
      __c_pointer, _Alloc>;
                          ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:114:69: error: invalid use of incomplete type ‘class std::__undefined’
  = __detected_or_t<__ptr_rebind<pointer, void>, __v_pointer, _Alloc>;
                                                                     ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:124:13: error: invalid use of incomplete type ‘class std::__undefined’
      _Alloc>;
             ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:134:26: error: invalid use of incomplete type ‘class std::__undefined’
      __diff_type, _Alloc>;
                          ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h:144:26: error: invalid use of incomplete type ‘class std::__undefined’
      __size_type, _Alloc>;
                          ^
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/bits/move.h:57:0,
                 from /usr/include/c++/6/bits/nested_exception.h:40,
                 from /usr/include/c++/6/exception:173,
                 from /usr/include/c++/6/ios:39,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/type_traits: In instantiation of ‘struct std::is_empty<std::__undefined>’:
/usr/include/c++/6/bits/alloc_traits.h:180:69:   required from ‘struct std::allocator_traits<std::__undefined>’
/usr/include/c++/6/ext/alloc_traits.h:50:10:   required from ‘struct __gnu_cxx::__alloc_traits<std::__undefined>’
/usr/include/c++/6/bits/stl_vector.h:77:9:   required from ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >’
/usr/include/c++/6/bits/stl_vector.h:214:11:   required from ‘class std::vector<int, StaticAllocator<int, 256ul> >’
prog.cpp:32:25:   required from here
/usr/include/c++/6/type_traits:701:12: error: invalid use of incomplete type ‘class std::__undefined’
     struct is_empty
            ^~~~~~~~
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/ext/alloc_traits.h:36:0,
                 from /usr/include/c++/6/bits/basic_string.h:40,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/alloc_traits.h: In instantiation of ‘struct std::allocator_traits<std::__undefined>’:
/usr/include/c++/6/ext/alloc_traits.h:50:10:   required from ‘struct __gnu_cxx::__alloc_traits<std::__undefined>’
/usr/include/c++/6/bits/stl_vector.h:77:9:   required from ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >’
/usr/include/c++/6/bits/stl_vector.h:214:11:   required from ‘class std::vector<int, StaticAllocator<int, 256ul> >’
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/alloc_traits.h:180:69: error: no type named ‘type’ in ‘struct std::is_empty<std::__undefined>’
  = __detected_or_t<typename is_empty<_Alloc>::type, __equal, _Alloc>;
                                                                     ^
/usr/include/c++/6/bits/alloc_traits.h:187:21: error: invalid use of incomplete type ‘class std::__undefined’
       static_assert(!is_same<rebind_alloc<value_type>, __undefined>::value,
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘class std::__undefined’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/bits/basic_string.h:40:0,
                 from /usr/include/c++/6/string:52,
                 from /usr/include/c++/6/bits/locale_classes.h:40,
                 from /usr/include/c++/6/bits/ios_base.h:41,
                 from /usr/include/c++/6/ios:42,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/ext/alloc_traits.h: In instantiation of ‘struct __gnu_cxx::__alloc_traits<std::__undefined>’:
/usr/include/c++/6/bits/stl_vector.h:77:9:   required from ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >’
/usr/include/c++/6/bits/stl_vector.h:214:11:   required from ‘class std::vector<int, StaticAllocator<int, 256ul> >’
prog.cpp:32:25:   required from here
/usr/include/c++/6/ext/alloc_traits.h:66:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka std::allocator_traits<std::__undefined>}::allocate’ in ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka struct std::allocator_traits<std::__undefined>}’
     using _Base_type::allocate;
                       ^~~~~~~~
/usr/include/c++/6/ext/alloc_traits.h:67:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka std::allocator_traits<std::__undefined>}::deallocate’ in ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka struct std::allocator_traits<std::__undefined>}’
     using _Base_type::deallocate;
                       ^~~~~~~~~~
/usr/include/c++/6/ext/alloc_traits.h:70:23: error: no members matching ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka std::allocator_traits<std::__undefined>}::max_size’ in ‘__gnu_cxx::__alloc_traits<std::__undefined>::_Base_type {aka struct std::allocator_traits<std::__undefined>}’
     using _Base_type::max_size;
                       ^~~~~~~~
In file included from /usr/include/c++/6/vector:64:0,
                 from /usr/include/c++/6/queue:61,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:86,
                 from prog.cpp:1:
/usr/include/c++/6/bits/stl_vector.h: In instantiation of ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’:
/usr/include/c++/6/bits/stl_vector.h:164:20:   required from ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >’
/usr/include/c++/6/bits/stl_vector.h:214:11:   required from ‘class std::vector<int, StaticAllocator<int, 256ul> >’
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/stl_vector.h:79:14: error: invalid use of incomplete type ‘std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Tp_alloc_type {aka class std::__undefined}’
       struct _Vector_impl
              ^~~~~~~~~~~~
In file included from /usr/include/c++/6/bits/stl_iterator.h:66:0,
                 from /usr/include/c++/6/bits/stl_algobase.h:67,
                 from /usr/include/c++/6/bits/char_traits.h:39,
                 from /usr/include/c++/6/ios:40,
                 from /usr/include/c++/6/istream:38,
                 from /usr/include/c++/6/sstream:38,
                 from /usr/include/c++/6/complex:45,
                 from /usr/include/c++/6/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52,
                 from prog.cpp:1:
/usr/include/c++/6/bits/ptr_traits.h:41:9: note: forward declaration of ‘std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Tp_alloc_type {aka class std::__undefined}’
   class __undefined;
         ^~~~~~~~~~~
In file included from /usr/include/c++/6/vector:64:0,
                 from /usr/include/c++/6/queue:61,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:86,
                 from prog.cpp:1:
/usr/include/c++/6/bits/stl_vector.h: In instantiation of ‘class std::vector<int, StaticAllocator<int, 256ul> >’:
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/stl_vector.h:243:20: error: no members matching ‘std::vector<int, StaticAllocator<int, 256ul> >::_Base {aka std::_Vector_base<int, StaticAllocator<int, 256ul> >}::_M_allocate’ in ‘std::vector<int, StaticAllocator<int, 256ul> >::_Base {aka struct std::_Vector_base<int, StaticAllocator<int, 256ul> >}’
       using _Base::_M_allocate;
                    ^~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:244:20: error: no members matching ‘std::vector<int, StaticAllocator<int, 256ul> >::_Base {aka std::_Vector_base<int, StaticAllocator<int, 256ul> >}::_M_deallocate’ in ‘std::vector<int, StaticAllocator<int, 256ul> >::_Base {aka struct std::_Vector_base<int, StaticAllocator<int, 256ul> >}’
       using _Base::_M_deallocate;
                    ^~~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h: In instantiation of ‘std::vector<_Tp, _Alloc>::~vector() [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>]’:
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/stl_vector.h:426:37: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_start’; did you mean ‘_M_swap_data’?
       { std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish,
                       ~~~~~~~~~~~~~~^~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:426:61: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_finish’
       { std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish,
                                               ~~~~~~~~~~~~~~^~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h: In instantiation of ‘std::_Vector_base<_Tp, _Alloc>::_Vector_base(const allocator_type&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::_Vector_base<_Tp, _Alloc>::allocator_type = StaticAllocator<int, 256ul>]’:
/usr/include/c++/6/bits/stl_vector.h:267:18:   required from ‘std::vector<_Tp, _Alloc>::vector(const allocator_type&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::vector<_Tp, _Alloc>::allocator_type = StaticAllocator<int, 256ul>]’
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/stl_vector.h:128:20: error: no matching function for call to ‘std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl::_Vector_impl(const allocator_type&)’
       : _M_impl(__a) { }
                    ^
/usr/include/c++/6/bits/stl_vector.h:95:2: note: candidate: std::_Vector_base<_Tp, _Alloc>::_Vector_impl::_Vector_impl(std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type&&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type = std::__undefined]
  _Vector_impl(_Tp_alloc_type&& __a) noexcept
  ^~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:95:2: note:   no known conversion for argument 1 from ‘const allocator_type {aka const StaticAllocator<int, 256ul>}’ to ‘std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Tp_alloc_type&& {aka std::__undefined&&}’
/usr/include/c++/6/bits/stl_vector.h:90:2: note: candidate: std::_Vector_base<_Tp, _Alloc>::_Vector_impl::_Vector_impl(const _Tp_alloc_type&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type = std::__undefined]
  _Vector_impl(_Tp_alloc_type const& __a) _GLIBCXX_NOEXCEPT
  ^~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:90:2: note:   no known conversion for argument 1 from ‘const allocator_type {aka const StaticAllocator<int, 256ul>}’ to ‘const _Tp_alloc_type& {aka const std::__undefined&}’
/usr/include/c++/6/bits/stl_vector.h:86:2: note: candidate: std::_Vector_base<_Tp, _Alloc>::_Vector_impl::_Vector_impl() [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>]
  _Vector_impl()
  ^~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:86:2: note:   candidate expects 0 arguments, 1 provided
/usr/include/c++/6/bits/stl_vector.h:79:14: note: candidate: constexpr std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl::_Vector_impl(const std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl&)
       struct _Vector_impl
              ^~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:79:14: note:   no known conversion for argument 1 from ‘const allocator_type {aka const StaticAllocator<int, 256ul>}’ to ‘const std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl&’
/usr/include/c++/6/bits/stl_vector.h:79:14: note: candidate: constexpr std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl::_Vector_impl(std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl&&)
/usr/include/c++/6/bits/stl_vector.h:79:14: note:   no known conversion for argument 1 from ‘const allocator_type {aka const StaticAllocator<int, 256ul>}’ to ‘std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl&&’
/usr/include/c++/6/bits/stl_vector.h: In instantiation of ‘std::_Vector_base<_Tp, _Alloc>::~_Vector_base() [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>]’:
/usr/include/c++/6/bits/stl_vector.h:267:18:   required from ‘std::vector<_Tp, _Alloc>::vector(const allocator_type&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::vector<_Tp, _Alloc>::allocator_type = StaticAllocator<int, 256ul>]’
prog.cpp:32:25:   required from here
/usr/include/c++/6/bits/stl_vector.h:160:37: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_start’; did you mean ‘_M_swap_data’?
       { _M_deallocate(this->_M_impl._M_start, this->_M_impl._M_end_of_storage
                       ~~~~~~~~~~~~~~^~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:160:61: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_end_of_storage’
       { _M_deallocate(this->_M_impl._M_start, this->_M_impl._M_end_of_storage
                                               ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:161:25: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_start’; did you mean ‘_M_swap_data’?
         - this->_M_impl._M_start); }
           ~~~~~~~~~~~~~~^~~~~~~~
/usr/include/c++/6/bits/stl_vector.h:160:22: error: ‘_M_deallocate’ was not declared in this scope
       { _M_deallocate(this->_M_impl._M_start, this->_M_impl._M_end_of_storage
         ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         - this->_M_impl._M_start); }
         ~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/6/vector:69:0,
                 from /usr/include/c++/6/queue:61,
                 from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:86,
                 from prog.cpp:1:
/usr/include/c++/6/bits/vector.tcc: In instantiation of ‘void std::vector<_Tp, _Alloc>::emplace_back(_Args&& ...) [with _Args = {int}; _Tp = int; _Alloc = StaticAllocator<int, 256ul>]’:
/usr/include/c++/6/bits/stl_vector.h:933:9:   required from ‘void std::vector<_Tp, _Alloc>::push_back(std::vector<_Tp, _Alloc>::value_type&&) [with _Tp = int; _Alloc = StaticAllocator<int, 256ul>; std::vector<_Tp, _Alloc>::value_type = int]’
prog.cpp:33:21:   required from here
/usr/include/c++/6/bits/vector.tcc:94:20: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_finish’
  if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage)
      ~~~~~~~~~~~~~~^~~~~~~~~
/usr/include/c++/6/bits/vector.tcc:94:47: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_end_of_storage’
  if (this->_M_impl._M_finish != this->_M_impl._M_end_of_storage)
                                 ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/6/bits/vector.tcc:96:60: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_finish’
      _Alloc_traits::construct(this->_M_impl, this->_M_impl._M_finish,
                                              ~~~~~~~~~~~~~~^~~~~~~~~
/usr/include/c++/6/bits/vector.tcc:98:22: error: ‘struct std::_Vector_base<int, StaticAllocator<int, 256ul> >::_Vector_impl’ has no member named ‘_M_finish’
      ++this->_M_impl._M_finish;
        ~~~~~~~~~~~~~~^~~~~~~~~
stdout
Standard output is empty