Don't use C++ features when building test code as C.

This fixes the build after a6efdb7 which added a method to a test used in both
C++ and C test cases.