For years *one* of the *many* ways we've made reliable C++ embedded is by forbidding dynamic storage (except heap). Typically that requires:
- no exceptions or RTTI
- class new/delete/new[]/delete[] over-ridden with HCF
- all free-storage run-time pruned from the libraries
- minor compiler-specific stubs for un-used C++ stuff
A quick C++ trial showed that generated code didn't drag too much stuff in: only thing I see first pass is a pure base class vtable calls a "you-called-a-pure-virtual-function-you-idiot" function that dragged in free storage (easy to stub out).
For g++ on cortex-M, is there a standard way to do this? I didn't find anything at first Google... The toolchain I'm using is set up for nano.
Thanks in advance for any pointers! Best Regards, Dave