C++ exceptions in your firmware code?
Not in my. But in ESP32 BLE library. But, yes, exceptions in code.
Well… Your solution is simple and work!
; Build options
build_flags = -fexceptions
into platformio.ini and project built successfully.
But. This way is not documented / no samples in build_flags option description
There is table with assembler, linker, defines, etc. Not obvious (for not-pro, Arduino users, for example) to use options without -D, -W, etc. prefixes at all. All present samples with different prefixes only,
So, i suppose it would be good to add such, not prefixed sample into docs too.