1#include <cstdint>
2#include <vector>
3
4extern "C" int LLVMFuzzerTestOneInput(const std::uint8_t *data, size_t size) {
5 std::vector<uint8_t> v;
6 // Intentionally throw std::length_error
7 v.reserve(n: static_cast<uint64_t>(-1));
8
9 return 0;
10}
11

source code of compiler-rt/test/fuzzer/UncaughtException.cpp