Fixes one or two subtle issues. But the more interesting fix is that I implemented puts in terms of DeepState_Log. Calls to printf that had no format arguments are transformed by the compiler into calls to puts, but that wasn't being wrapped by DeepState, so it was appearing as though those log messages never actually happened.
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
#include <deepstate/DeepState.hpp>
|
||||
|
||||
/*
|
||||
TEST(Streaming, BasicLevels) {
|
||||
LOG(DEBUG) << "This is a debug message";
|
||||
LOG(INFO) << "This is an info message";
|
||||
@@ -32,11 +32,12 @@ TEST(Streaming, BasicTypes) {
|
||||
LOG(INFO) << "string";
|
||||
LOG(INFO) << nullptr;
|
||||
}
|
||||
|
||||
*/
|
||||
TEST(Formatting, OverridePrintf) {
|
||||
printf("hello string=%s hex_lower=%x hex_upper=%X octal=%o char=%c dec=%d"
|
||||
"double=%f sci=%e SCI=%E pointer=%p",
|
||||
"world", 999, 999, 999, 'a', 999, 999.0, 999.0, 999.0, "world");
|
||||
printf("hello again!");
|
||||
}
|
||||
|
||||
int main(void) {
|
||||
|
||||
Reference in New Issue
Block a user