Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Language

C++

Compiler

gcc 12.3.0

Options
Warnings
Optimization
Boost 1.81.0
C++2b(GNU)
no pedantic
Raw compiler options
assertion_failed.cc

assertion_failed.cc

$ g++ prog.cc -Wall -Wextra -O2 -march=native -I/opt/wandbox/boost-1.81.0-gcc-12.3.0/include -std=gnu++2b assertion_failed.cc
In file included from /opt/wandbox/boost-1.81.0-gcc-12.3.0/include/boost/heap/fibonacci_heap.hpp:16,
                 from prog.cc:10:
In member function 'T& boost::array<T, N>::operator[](size_type) [with T = boost::heap::detail::marked_heap_node<int>*; long unsigned int N = 64]',
    inlined from 'void boost::heap::fibonacci_heap<T, A0, A1, A2, A3, A4>::consolidate() [with T = int; A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_]' at /opt/wandbox/boost-1.81.0-gcc-12.3.0/include/boost/heap/fibonacci_heap.hpp:715:20:
/opt/wandbox/boost-1.81.0-gcc-12.3.0/include/boost/array.hpp:117:68: warning: array subscript 64 is above array bounds of 'boost::heap::detail::marked_heap_node<int>* [64]' [-Warray-bounds]
  117 |             return BOOST_ASSERT_MSG( i < N, "out of range" ), elems[i];
      |                                                               ~~~~~^
/opt/wandbox/boost-1.81.0-gcc-12.3.0/include/boost/array.hpp: In member function 'void boost::heap::fibonacci_heap<T, A0, A1, A2, A3, A4>::consolidate() [with T = int; A0 = boost::parameter::void_; A1 = boost::parameter::void_; A2 = boost::parameter::void_; A3 = boost::parameter::void_; A4 = boost::parameter::void_]':
/opt/wandbox/boost-1.81.0-gcc-12.3.0/include/boost/array.hpp:62:11: note: while referencing 'boost::array<boost::heap::detail::marked_heap_node<int>*, 64>::elems'
   62 |         T elems[N];    // fixed-size array of elements of type T
      |           ^~~~~
Exit Code:
0