sol2/tests/regression_tests/simple/source/main.cpp
ThePhD ef33531df4
Fix most of the most pressing warnings
- Fixes #1000
- Fixes #1060
- Fixes #1062
- Fixes #1067
2020-11-19 16:42:02 -05:00

17 lines
489 B
C++

#include <cstddef>
extern int regression_1000();
extern int regression_1008();
extern int regression_1067();
int main(int, char*[]) {
using f_ptr = int (*)();
const f_ptr regressions[] = { &regression_1008, &regression_1000, &regression_1067 };
const int sizeof_regressions = sizeof(regressions) / sizeof(regressions[0]);
int r = 0;
for (std::size_t i = 0; i < sizeof_regressions; ++i) {
f_ptr f = regressions[0];
r += static_cast<int>(f() != 0);
}
return r;
}