/ Vijos /

记录详情

Compile Error

foo.cc:1:1: error: 'include' does not name a type
    1 | include <cstdio>
      | ^~~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:361:31: error: 'std::size_t' has not been declared
  361 |   template<typename _Tp, std::size_t _Size>
      |                               ^~~~~~
/usr/include/c++/9/type_traits:362:25: error: '_Size' was not declared in this scope
  362 |     struct is_array<_Tp[_Size]>
      |                         ^~~~~
/usr/include/c++/9/type_traits:362:31: error: template argument 1 is invalid
  362 |     struct is_array<_Tp[_Size]>
      |                               ^
/usr/include/c++/9/type_traits:560:42: error: 'nullptr_t' is not a member of 'std'
  560 |     struct __is_null_pointer_helper<std::nullptr_t>
      |                                          ^~~~~~~~~
/usr/include/c++/9/type_traits:560:42: error: 'nullptr_t' is not a member of 'std'
/usr/include/c++/9/type_traits:560:51: error: template argument 1 is invalid
  560 |     struct __is_null_pointer_helper<std::nullptr_t>
      |                                                   ^
/usr/include/c++/9/type_traits:1253:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1253 |     : public integral_constant<std::size_t, alignof(_Tp)> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1253:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1253 |     : public integral_constant<std::size_t, alignof(_Tp)> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1253:57: error: template argument 1 is invalid
 1253 |     : public integral_constant<std::size_t, alignof(_Tp)> { };
      |                                                         ^
/usr/include/c++/9/type_traits:1253:57: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1258:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1258 |     : public integral_constant<std::size_t, 0> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1258:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1258 |     : public integral_constant<std::size_t, 0> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1258:46: error: template argument 1 is invalid
 1258 |     : public integral_constant<std::size_t, 0> { };
      |                                              ^
/usr/include/c++/9/type_traits:1258:46: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1260:31: error: 'std::size_t' has not been declared
 1260 |   template<typename _Tp, std::size_t _Size>
      |                               ^~~~~~
/usr/include/c++/9/type_traits:1261:21: error: '_Size' was not declared in this scope
 1261 |     struct rank<_Tp[_Size]>
      |                     ^~~~~
/usr/include/c++/9/type_traits:1261:27: error: template argument 1 is invalid
 1261 |     struct rank<_Tp[_Size]>
      |                           ^
/usr/include/c++/9/type_traits:1262:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1262 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1262:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1262 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1262:65: error: template argument 1 is invalid
 1262 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                                                 ^
/usr/include/c++/9/type_traits:1262:65: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1266:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1266 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1266:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1266 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1266:65: error: template argument 1 is invalid
 1266 |     : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
      |                                                                 ^
/usr/include/c++/9/type_traits:1266:65: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1271:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1271 |     : public integral_constant<std::size_t, 0> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1271:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1271 |     : public integral_constant<std::size_t, 0> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1271:46: error: template argument 1 is invalid
 1271 |     : public integral_constant<std::size_t, 0> { };
      |                                              ^
/usr/include/c++/9/type_traits:1271:46: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1273:47: error: 'std::size_t' has not been declared
 1273 |   template<typename _Tp, unsigned _Uint, std::size_t _Size>
      |                                               ^~~~~~
/usr/include/c++/9/type_traits:1274:23: error: '_Size' was not declared in this scope
 1274 |     struct extent<_Tp[_Size], _Uint>
      |                       ^~~~~
/usr/include/c++/9/type_traits:1274:36: error: template argument 1 is invalid
 1274 |     struct extent<_Tp[_Size], _Uint>
      |                                    ^
/usr/include/c++/9/type_traits:1275:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1275 |     : public integral_constant<std::size_t,
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1275:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1275 |     : public integral_constant<std::size_t,
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1276:24: error: '_Size' was not declared in this scope
 1276 |           _Uint == 0 ? _Size : extent<_Tp,
      |                        ^~~~~
/usr/include/c++/9/type_traits:1277:28: error: template argument 1 is invalid
 1277 |           _Uint - 1>::value>
      |                            ^
/usr/include/c++/9/type_traits:1277:28: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1282:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1282 |     : public integral_constant<std::size_t,
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1282:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
 1282 |     : public integral_constant<std::size_t,
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/move.h:55,
                 from /usr/include/c++/9/bits/stl_pair.h:59,
                 from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/type_traits:1284:31: error: template argument 1 is invalid
 1284 |              _Uint - 1>::value>
      |                               ^
/usr/include/c++/9/type_traits:1284:31: note: invalid template non-type parameter
/usr/include/c++/9/type_traits:1839:31: error: 'std::size_t' has not been declared
 1839 |   template<typename _Tp, std::size_t _Size>
      |                               ^~~~~~
/usr/include/c++/9/type_traits:1840:30: error: '_Size' was not declared in this scope
 1840 |     struct remove_extent<_Tp[_Size]>
      |                              ^~~~~
/usr/include/c++/9/type_traits:1840:36: error: template argument 1 is invalid
 1840 |     struct remove_extent<_Tp[_Size]>
      |                                    ^
/usr/include/c++/9/type_traits:1852:31: error: 'std::size_t' has not been declared
 1852 |   template<typename _Tp, std::size_t _Size>
      |                               ^~~~~~
/usr/include/c++/9/type_traits:1853:35: error: '_Size' was not declared in this scope
 1853 |     struct remove_all_extents<_Tp[_Size]>
      |                                   ^~~~~
/usr/include/c++/9/type_traits:1853:41: error: template argument 1 is invalid
 1853 |     struct remove_all_extents<_Tp[_Size]>
      |                                         ^
/usr/include/c++/9/type_traits:1911:17: error: 'std::size_t' has not been declared
 1911 |   template<std::size_t _Len>
      |                 ^~~~~~
/usr/include/c++/9/type_traits:1916:23: error: '_Len' was not declared in this scope
 1916 |  unsigned char __data[_Len];
      |                       ^~~~
/usr/include/c++/9/type_traits:1931:17: error: 'std::size_t' has not been declared
 1931 |   template<std::size_t _Len, std::size_t _Align =
      |                 ^~~~~~
/usr/include/c++/9/type_traits:1931:35: error: 'std::size_t' has not been declared
 1931 |   template<std::size_t _Len, std::size_t _Align =
      |                                   ^~~~~~
/usr/include/c++/9/type_traits:1932:48: error: '_Len' was not declared in this scope
 1932 |     __alignof__(typename __aligned_storage_msa<_Len>::__type)>
      |                                                ^~~~
/usr/include/c++/9/type_traits:1932:52: error: template argument 1 is invalid
 1932 |     __alignof__(typename __aligned_storage_msa<_Len>::__type)>
      |                                                    ^
/usr/include/c++/9/type_traits:1937:23: error: '_Len' was not declared in this scope
 1937 |  unsigned char __data[_Len];
      |                       ^~~~
/usr/include/c++/9/type_traits:1938:37: error: '_Align' was not declared in this scope
 1938 |  struct __attribute__((__aligned__((_Align)))) { } __align;
      |                                     ^~~~~~
In file included from /usr/include/c++/9/utility:70,
                 from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_pair.h:86:17: error: 'std::size_t' has not been declared
   86 |   template<std::size_t...>
      |                 ^~~~~~
/usr/include/c++/9/bits/stl_pair.h:434:41: error: 'std::size_t' has not been declared
  434 |       template<typename... _Args1, std::size_t... _Indexes1,
      |                                         ^~~~~~
/usr/include/c++/9/bits/stl_pair.h:435:41: error: 'std::size_t' has not been declared
  435 |                typename... _Args2, std::size_t... _Indexes2>
      |                                         ^~~~~~
/usr/include/c++/9/bits/stl_pair.h:437:27: error: '_Indexes1' was not declared in this scope
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                           ^~~~~~~~~
/usr/include/c++/9/bits/stl_pair.h:437:36: error: expected parameter pack before '...'
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                                    ^~~
/usr/include/c++/9/bits/stl_pair.h:437:39: error: template argument 1 is invalid
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                                       ^
/usr/include/c++/9/bits/stl_pair.h:437:55: error: '_Indexes2' was not declared in this scope
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                                                       ^~~~~~~~~
/usr/include/c++/9/bits/stl_pair.h:437:64: error: expected parameter pack before '...'
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                                                                ^~~
/usr/include/c++/9/bits/stl_pair.h:437:67: error: template argument 1 is invalid
  437 |              _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
      |                                                                   ^
In file included from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/utility:109:17: error: 'std::size_t' has not been declared
  109 |   template<std::size_t __i, typename _Tp>
      |                 ^~~~~~
/usr/include/c++/9/utility:110:12: error: no default argument for '_Tp'
  110 |     struct tuple_element;
      |            ^~~~~~~~~~~~~
/usr/include/c++/9/utility:113:17: error: 'std::size_t' has not been declared
  113 |   template<std::size_t __i, typename _Tp>
      |                 ^~~~~~
/usr/include/c++/9/utility:114:54: error: '__i' was not declared in this scope
  114 |     using __tuple_element_t = typename tuple_element<__i, _Tp>::type;
      |                                                      ^~~
/usr/include/c++/9/utility:114:62: error: template argument 1 is invalid
  114 |     using __tuple_element_t = typename tuple_element<__i, _Tp>::type;
      |                                                              ^
/usr/include/c++/9/utility:116:17: error: 'std::size_t' has not been declared
  116 |   template<std::size_t __i, typename _Tp>
      |                 ^~~~~~
/usr/include/c++/9/utility:117:26: error: '__i' was not declared in this scope
  117 |     struct tuple_element<__i, const _Tp>
      |                          ^~~
/usr/include/c++/9/utility:117:40: error: template argument 1 is invalid
  117 |     struct tuple_element<__i, const _Tp>
      |                                        ^
/usr/include/c++/9/utility:122:17: error: 'std::size_t' has not been declared
  122 |   template<std::size_t __i, typename _Tp>
      |                 ^~~~~~
/usr/include/c++/9/utility:123:26: error: '__i' was not declared in this scope
  123 |     struct tuple_element<__i, volatile _Tp>
      |                          ^~~
/usr/include/c++/9/utility:123:43: error: template argument 1 is invalid
  123 |     struct tuple_element<__i, volatile _Tp>
      |                                           ^
/usr/include/c++/9/utility:128:17: error: 'std::size_t' has not been declared
  128 |   template<std::size_t __i, typename _Tp>
      |                 ^~~~~~
/usr/include/c++/9/utility:129:26: error: '__i' was not declared in this scope
  129 |     struct tuple_element<__i, const volatile _Tp>
      |                          ^~~
/usr/include/c++/9/utility:129:49: error: template argument 1 is invalid
  129 |     struct tuple_element<__i, const volatile _Tp>
      |                                                 ^
/usr/include/c++/9/utility:154:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
  154 |     : public integral_constant<std::size_t, 2> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/utility:154:37: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
  154 |     : public integral_constant<std::size_t, 2> { };
      |                                     ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/algorithm:60,
                 from foo.cc:3:
/usr/include/c++/9/utility:154:46: error: template argument 1 is invalid
  154 |     : public integral_constant<std::size_t, 2> { };
      |                                              ^
/usr/include/c++/9/utility:154:46: note: invalid template non-type parameter
/usr/include/c++/9/utility:166:17: error: 'std::size_t' has not been declared
  166 |   template<std::size_t _Int>
      |                 ^~~~~~
/usr/include/c++/9/utility:217:17: error: 'std::size_t' has not been declared
  217 |   template<std::size_t _Int, class _Tp1, class _Tp2>
      |                 ^~~~~~
/usr/include/c++/9/utility:218:38: error: '_Int' was not declared in this scope
  218 |     constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&
      |                                      ^~~~
/usr/include/c++/9/utility:218:64: error: template argument 1 is invalid
  218 |     constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&
      |                                                                ^~
/usr/include/c++/9/utility: In function 'constexpr int& std::get(std::pair<_Tp1, _Tp2>&)':
/usr/include/c++/9/utility:220:25: error: '_Int' was not declared in this scope
  220 |     { return __pair_get<_Int>::__get(__in); }
      |                         ^~~~
/usr/include/c++/9/utility:220:29: error: template argument 1 is invalid
  220 |     { return __pair_get<_Int>::__get(__in); }
      |                             ^
/usr/include/c++/9/utility: At global scope:
/usr/include/c++/9/utility:222:17: error: 'std::size_t' has not been declared
  222 |   template<std::size_t _Int, class _Tp1, class _Tp2>
      |                 ^~~~~~
/usr/include/c++/9/utility:223:38: error: '_Int' was not declared in this scope
  223 |     constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&&
      |                                      ^~~~
/usr/include/c++/9/utility:223:64: error: template argument 1 is invalid
  223 |     constexpr typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&&
      |                                                                ^~
/usr/include/c++/9/utility: In function 'constexpr int&& std::get(std::pair<_Tp1, _Tp2>&&)':
/usr/include/c++/9/utility:225:25: error: '_Int' was not declared in this scope
  225 |     { return __pair_get<_Int>::__move_get(std::move(__in)); }
      |                         ^~~~
/usr/include/c++/9/utility:225:29: error: template argument 1 is invalid
  225 |     { return __pair_get<_Int>::__move_get(std::move(__in)); }
      |                             ^
/usr/include/c++/9/utility: At global scope:
/usr/include/c++/9/utility:227:17: error: 'std::size_t' has not been declared
  227 |   template<std::size_t _Int, class _Tp1, class _Tp2>
      |                 ^~~~~~
/usr/include/c++/9/utility:228:44: error: '_Int' was not declared in this scope
  228 |     constexpr const typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&
      |                                            ^~~~
/usr/include/c++/9/utility:228:70: error: template argument 1 is invalid
  228 |     constexpr const typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&
      |                                                                      ^~
/usr/include/c++/9/utility: In function 'constexpr const int& std::get(const std::pair<_Tp1, _Tp2>&)':
/usr/include/c++/9/utility:230:25: error: '_Int' was not declared in this scope
  230 |     { return __pair_get<_Int>::__const_get(__in); }
      |                         ^~~~
/usr/include/c++/9/utility:230:29: error: template argument 1 is invalid
  230 |     { return __pair_get<_Int>::__const_get(__in); }
      |                             ^
/usr/include/c++/9/utility: At global scope:
/usr/include/c++/9/utility:232:17: error: 'std::size_t' has not been declared
  232 |   template<std::size_t _Int, class _Tp1, class _Tp2>
      |                 ^~~~~~
/usr/include/c++/9/utility:233:44: error: '_Int' was not declared in this scope
  233 |     constexpr const typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&&
      |                                            ^~~~
/usr/include/c++/9/utility:233:70: error: template argument 1 is invalid
  233 |     constexpr const typename tuple_element<_Int, std::pair<_Tp1, _Tp2>>::type&&
      |                                                                      ^~
/usr/include/c++/9/utility: In function 'constexpr const int&& std::get(const std::pair<_Tp1, _Tp2>&&)':
/usr/include/c++/9/utility:235:25: error: '_Int' was not declared in this scope
  235 |     { return __pair_get<_Int>::__const_move_get(std::move(__in)); }
      |                         ^~~~
/usr/include/c++/9/utility:235:29: error: template argument 1 is invalid
  235 |     { return __pair_get<_Int>::__const_move_get(std::move(__in)); }
      |                             ^
/usr/include/c++/9/utility: At global scope:
/usr/include/c++/9/utility:310:58: note: invalid template non-type parameter
  310 |       using __type = _Index_tuple<__integer_pack(_Num)...>;
      |                                                          ^
In file included from /usr/include/c++/9/bits/stl_algobase.h:62,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/ext/type_traits.h:162:35: error: 'bool __gnu_cxx::__is_null_pointer' redeclared as different kind of entity
  162 |   __is_null_pointer(std::nullptr_t)
      |                                   ^
/usr/include/c++/9/ext/type_traits.h:157:5: note: previous declaration 'template<class _Type> bool __gnu_cxx::__is_null_pointer(_Type)'
  157 |     __is_null_pointer(_Type)
      |     ^~~~~~~~~~~~~~~~~
/usr/include/c++/9/ext/type_traits.h:162:26: error: 'nullptr_t' is not a member of 'std'
  162 |   __is_null_pointer(std::nullptr_t)
      |                          ^~~~~~~~~
In file included from /usr/include/c++/9/bits/stl_algobase.h:65,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_iterator_base_types.h:116:67: error: 'ptrdiff_t' does not name a type
  116 |   template<typename _Category, typename _Tp, typename _Distance = ptrdiff_t,
      |                                                                   ^~~~~~~~~
In file included from /usr/include/c++/9/bits/stl_algobase.h:65,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_iterator_base_types.h:1:1: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
  +++ |+#include <cstddef>
    1 | // Types used in iterator implementation -*- C++ -*-
In file included from /usr/include/c++/9/bits/stl_algobase.h:65,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_iterator_base_types.h:182:15: error: 'ptrdiff_t' does not name a type
  182 |       typedef ptrdiff_t                   difference_type;
      |               ^~~~~~~~~
/usr/include/c++/9/bits/stl_iterator_base_types.h:182:15: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
/usr/include/c++/9/bits/stl_iterator_base_types.h:193:15: error: 'ptrdiff_t' does not name a type
  193 |       typedef ptrdiff_t                   difference_type;
      |               ^~~~~~~~~
/usr/include/c++/9/bits/stl_iterator_base_types.h:193:15: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
In file included from /usr/include/c++/9/bits/stl_algobase.h:66,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_iterator_base_funcs.h:110:5: error: 'ptrdiff_t' does not name a type
  110 |     ptrdiff_t
      |     ^~~~~~~~~
/usr/include/c++/9/bits/stl_iterator_base_funcs.h:66:1: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
   65 | #include <debug/assertions.h>
  +++ |+#include <cstddef>
   66 | 
/usr/include/c++/9/bits/stl_iterator_base_funcs.h:116:5: error: 'ptrdiff_t' does not name a type
  116 |     ptrdiff_t
      |     ^~~~~~~~~
/usr/include/c++/9/bits/stl_iterator_base_funcs.h:116:5: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
In file included from /usr/include/c++/9/bits/stl_iterator.h:66,
                 from /usr/include/c++/9/bits/stl_algobase.h:67,
                 from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/ptr_traits.h:109:20: error: 'ptrdiff_t' was not declared in this scope
  109 |  = __detected_or_t<ptrdiff_t, __difference_type, _Ptr>;
      |                    ^~~~~~~~~
/usr/include/c++/9/bits/ptr_traits.h:1:1: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
  +++ |+#include <cstddef>
    1 | // Pointer Traits -*- C++ -*-
/usr/include/c++/9/bits/ptr_traits.h:109:54: error: template argument 1 is invalid
  109 |  = __detected_or_t<ptrdiff_t, __difference_type, _Ptr>;
      |                                                      ^
/usr/include/c++/9/bits/ptr_traits.h:135:15: error: 'ptrdiff_t' does not name a type
  135 |       typedef ptrdiff_t difference_type;
      |               ^~~~~~~~~
/usr/include/c++/9/bits/ptr_traits.h:135:15: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
In file included from /usr/include/c++/9/algorithm:61,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_algobase.h: In static member function 'static _Tp* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(const _Tp*, const _Tp*, _Tp*)':
/usr/include/c++/9/bits/stl_algobase.h:384:10: error: 'ptrdiff_t' does not name a type
  384 |    const ptrdiff_t _Num = __last - __first;
      |          ^~~~~~~~~
/usr/include/c++/9/bits/stl_algobase.h:72:1: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
   71 | #include <bits/predefined_ops.h>
  +++ |+#include <cstddef>
   72 | #if __cplusplus >= 201103L
/usr/include/c++/9/bits/stl_algobase.h:385:8: error: '_Num' was not declared in this scope
  385 |    if (_Num)
      |        ^~~~
/usr/include/c++/9/bits/stl_algobase.h:387:22: error: '_Num' was not declared in this scope
  387 |    return __result + _Num;
      |                      ^~~~
/usr/include/c++/9/bits/stl_algobase.h: In static member function 'static _Tp* std::__copy_move_backward<_IsMove, true, std::random_access_iterator_tag>::__copy_move_b(const _Tp*, const _Tp*, _Tp*)':
/usr/include/c++/9/bits/stl_algobase.h:586:10: error: 'ptrdiff_t' does not name a type
  586 |    const ptrdiff_t _Num = __last - __first;
      |          ^~~~~~~~~
/usr/include/c++/9/bits/stl_algobase.h:586:10: note: 'ptrdiff_t' is defined in header '<cstddef>'; did you forget to '#include <cstddef>'?
/usr/include/c++/9/bits/stl_algobase.h:587:8: error: '_Num' was not declared in this scope
  587 |    if (_Num)
      |        ^~~~
/usr/include/c++/9/bits/stl_algobase.h:589:22: error: '_Num' was not declared in this scope
  589 |    return __result - _Num;
      |                      ^~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new: At global scope:
/usr/include/c++/9/new:125:50: error: declaration of 'operator new' as non-function
  125 | _GLIBCXX_NODISCARD void* operator new(std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      |                                                  ^
/usr/include/c++/9/new:125:44: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
  125 | _GLIBCXX_NODISCARD void* operator new(std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      |                                            ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:126:41: error: attributes after parenthesized initializer ignored [-fpermissive]
  126 |   __attribute__((__externally_visible__));
      |                                         ^
/usr/include/c++/9/new:127:52: error: declaration of 'operator new []' as non-function
  127 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      |                                                    ^
/usr/include/c++/9/new:127:46: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
  127 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc)
      |                                              ^~~~~~
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:128:41: error: attributes after parenthesized initializer ignored [-fpermissive]
  128 |   __attribute__((__externally_visible__));
      |                                         ^
/usr/include/c++/9/new:139:44: error: declaration of 'operator new' as non-function
  139 | _GLIBCXX_NODISCARD void* operator new(std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      |                                            ^~~~~~
/usr/include/c++/9/new:139:44: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:139:52: error: expected primary-expression before 'const'
  139 | _GLIBCXX_NODISCARD void* operator new(std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      |                                                    ^~~~~
/usr/include/c++/9/new:141:46: error: declaration of 'operator new []' as non-function
  141 | _GLIBCXX_NODISCARD void* operator new[](std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      |                                              ^~~~~~
/usr/include/c++/9/new:141:46: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:141:54: error: expected primary-expression before 'const'
  141 | _GLIBCXX_NODISCARD void* operator new[](std::size_t, const std::nothrow_t&) _GLIBCXX_USE_NOEXCEPT
      |                                                      ^~~~~
/usr/include/c++/9/new:173:51: error: declaration of 'operator new' as non-function
  173 | _GLIBCXX_NODISCARD inline void* operator new(std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      |                                                   ^~~~~~
/usr/include/c++/9/new:173:51: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:173:59: error: expected primary-expression before 'void'
  173 | _GLIBCXX_NODISCARD inline void* operator new(std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      |                                                           ^~~~
/usr/include/c++/9/new:175:53: error: declaration of 'operator new []' as non-function
  175 | _GLIBCXX_NODISCARD inline void* operator new[](std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      |                                                     ^~~~~~
/usr/include/c++/9/new:175:53: error: 'size_t' is not a member of 'std'; did you mean 'size_t'?
In file included from /usr/include/stdlib.h:31,
                 from /usr/include/c++/9/cstdlib:75,
                 from foo.cc:2:
/usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h:209:23: note: 'size_t' declared here
  209 | typedef __SIZE_TYPE__ size_t;
      |                       ^~~~~~
In file included from /usr/include/c++/9/bits/stl_construct.h:59,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/new:175:61: error: expected primary-expression before 'void'
  175 | _GLIBCXX_NODISCARD inline void* operator new[](std::size_t, void* __p) _GLIBCXX_USE_NOEXCEPT
      |                                                             ^~~~
In file included from /usr/include/c++/9/ext/alloc_traits.h:36,
                 from /usr/include/c++/9/bits/stl_construct.h:61,
                 from /usr/include/c++/9/bits/stl_tempbuf.h:60,
                 from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/bits/alloc_traits.h:412:36: error: 'ptrdiff_t' in namespace 'std' does not name a type
  412 |       using difference_type = std::ptrdiff_t;
      |                                    ^~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:415:30: error: 'size_t' in namespace 'std' does not name a type
  415 |       using size_type = std::size_t;
      |                              ^~~~~~
/usr/include/c++/9/bits/alloc_traits.h:443:37: error: 'size_type' has not been declared
  443 |       allocate(allocator_type& __a, size_type __n)
      |                                     ^~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:457:37: error: 'size_type' has not been declared
  457 |       allocate(allocator_type& __a, size_type __n, const_void_pointer __hint)
      |                                     ^~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:469:52: error: 'size_type' has not been declared
  469 |       deallocate(allocator_type& __a, pointer __p, size_type __n)
      |                                                    ^~~~~~~~~
/usr/include/c++/9/bits/alloc_traits.h:504:14: error: 'size_type' does not name a type; did you mean 'true_type'?
  504 |       static size_type
      |              ^~~~~~~~~
      |              true_type
In file included from /usr/include/c++/9/bits/stl_algo.h:62,
                 from /usr/include/c++/9/algorithm:62,
                 from foo.cc:3:
/usr/include/c++/9/bits/stl_tempbuf.h: In function 'std::pair<_Tp*, long int> std::get_temporary_buffer(ptrdiff_t)':
/usr/include/c++/9/bits/stl_tempbuf.h:95:20: error: too many arguments to function 'void* operator new(long unsigned int)'
   95 |        std::nothrow));
      |                    ^
foo.cc: In function 'void print(int, int)':
foo.cc:13:1: error: 'printf' was not declared in this scope
   13 | printf("%d\n", num);
      | ^~~~~~
foo.cc:4:1: note: 'printf' is defined in header '<cstdio>'; did you forget to '#include <cstdio>'?
    3 | #include <algorithm>
  +++ |+#include <cstdio>
    4 | #define inf (1 << 30)
foo.cc:19:1: error: 'printf' was not declared in this scope
   19 | printf("%d\n", num);
      | ^~~~~~
foo.cc:19:1: note: 'printf' is defined in header '<cstdio>'; did you forget to '#include <cstdio>'?
foo.cc: In function 'int main(int, const char**)':
foo.cc:22:1: error: 'scanf' was not declared in this scope
   22 | scanf("%d %d", &m, &n);
      | ^~~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1139 小胖办证
语言
C++
递交时间
2022-02-02 12:07:00
评测时间
2022-02-02 12:07:00
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes