QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#570057#5145. Shortest PathDerekshakkCompile Error//C++175.1kb2024-09-17 13:35:332024-09-17 13:35:35

Details

In file included from /usr/include/x86_64-linux-gnu/c++/13/bits/c++allocator.h:33,
                 from /usr/include/c++/13/bits/allocator.h:46,
                 from /usr/include/c++/13/string:43,
                 from /usr/include/c++/13/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:52,
                 from answer.code:1:
/usr/include/c++/13/bits/new_allocator.h: In instantiation of ‘void std::__new_allocator<_Tp>::construct(_Up*, _Args&& ...) [with _Up = Segment; _Args = {int, long long int&, long long int&, int}; _Tp = Segment]’:
/usr/include/c++/13/bits/alloc_traits.h:537:17:   required from ‘static void std::allocator_traits<std::allocator<_CharT> >::construct(allocator_type&, _Up*, _Args&& ...) [with _Up = Segment; _Args = {int, long long int&, long long int&, int}; _Tp = Segment; allocator_type = std::allocator<Segment>]’
/usr/include/c++/13/bits/vector.tcc:117:30:   required from ‘std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::emplace_back(_Args&& ...) [with _Args = {int, long long int&, long long int&, int}; _Tp = Segment; _Alloc = std::allocator<Segment>; reference = Segment&]’
answer.code:151:41:   required from here
/usr/include/c++/13/bits/new_allocator.h:187:11: error: new initializer expression list treated as compound expression [-fpermissive]
  187 |         { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/new_allocator.h:187:11: error: no matching function for call to ‘Segment::Segment(int)’
answer.code:54:8: note: candidate: ‘Segment::Segment()’
   54 | struct Segment
      |        ^~~~~~~
answer.code:54:8: note:   candidate expects 0 arguments, 1 provided
answer.code:54:8: note: candidate: ‘constexpr Segment::Segment(const Segment&)’
answer.code:54:8: note:   no known conversion for argument 1 from ‘int’ to ‘const Segment&’
answer.code:54:8: note: candidate: ‘constexpr Segment::Segment(Segment&&)’
answer.code:54:8: note:   no known conversion for argument 1 from ‘int’ to ‘Segment&&’