libnonius / nonius

A C++ micro-benchmarking framework
https://nonius.io
Creative Commons Zero v1.0 Universal
358 stars 47 forks source link

HTML reporter fails when no benchmark has run #83

Open sehe opened 7 years ago

sehe commented 7 years ago

This is not a very big deal but may become more interesting when filtering/skipping has been implemented.

First SEGV potential is here:

 auto min = *std::min_element(mins.begin(), mins.end());

easily remedied:

 auto min = mins.empty()? fp_seconds{} : *std::min_element(mins.begin(), mins.end());

But then it fails in report generation, and I found it pretty hard to debug the cpptempl logic to see how to fix that.