mpusz / mp-units

The quantities and units library for C++
https://mpusz.github.io/mp-units/
MIT License
994 stars 79 forks source link

Can't compile with exceptions disabled #565

Closed sa2thoms closed 1 month ago

sa2thoms commented 2 months ago

My use-case is an embedded application where we have disabled all C++ exceptions (and all dynamic memory allocations - there is no operating system). It looks like some of the string-formatting related code throws exceptions. I think there should be a way to compile without including any of the formatting code, so we can avoid this in our application and similar embedded applications.

mpusz commented 2 months ago

I totally agree. I thought that the macros added some time to format.h should do the job. If not, we should fix it.