runner
runner copied to clipboard
C++ test framework pollutes the global namespace
When trying to run a piece of C++ code similar to:
char c;
int f (void) { return c; }
I got this error message:
./solution.cpp:27:57: error: reference to 'c' is ambiguous
...
/usr/local/include/igloo/core/testrunner.h:17:13: note: candidate found by name lookup is 'igloo::c'
namespace c = choices;
Where igloo pollutes the global namespace with identifier c
, a commonly used one character identifier in regular code.
I'm not even sure users are able/required to use that namespace, so why not make it invisible?