y3c-stl 0.3.3
Friendly C++ STL wrapper with automatic stacktrace
|
example output:
y3c-stl terminated: undefined behavior detected (ub_out_of_range)at y3c::vector<int>::operator[](): attempted to access index 3, that is outside the bounds of size 0.Stack trace (most recent call first):#0 0x0000563e3fff866e in main at /home/runner/work/y3c-stl/y3c-stl/build/../examples/vector-ptr.cc:6:274: int main() {5: y3c::vector<int> a;6: y3c::ptr<int> p = &a[3];7: p += 10;8: std::cout << *p << std::endl;ポインタ型wrap: element_type型のデータへのポインタと、 このポインタ自体の生存状態を管理するクラスDefinition wrap.h:318Definition array.h:8