diff --git a/examples/cpp-flat-layout/main.cpp b/examples/cpp-flat-layout/main.cpp index a220d446..0e09545a 100644 --- a/examples/cpp-flat-layout/main.cpp +++ b/examples/cpp-flat-layout/main.cpp @@ -1,6 +1,4 @@ - -#define OBX_CPP_FILE - +#define OBX_CPP_FILE #include "objectbox.hpp" @@ -24,7 +22,7 @@ int main(int argc, char* args[]) box.put(*task); // Update } - printf("Your task has ID=%llu, text=%s\n", + printf("Your task has ID=%" PRIu64 ", text=%s\n", id, box.get(id)->text.c_str()); diff --git a/examples/cpp/CMakeLists.txt b/examples/cpp/CMakeLists.txt index 1d0f0596..00d8e3e6 100644 --- a/examples/cpp/CMakeLists.txt +++ b/examples/cpp/CMakeLists.txt @@ -36,7 +36,7 @@ if (DO_INSOURCE) src/schema/monster.fbs src/schema/another_monster.fbs INSOURCE - CXX_STANDARD 14 + CXX_STANDARD 14 ) target_include_directories(objectbox-test PRIVATE src/schema) else() diff --git a/examples/cpp/src/main.cpp b/examples/cpp/src/main.cpp index a220d446..0e09545a 100644 --- a/examples/cpp/src/main.cpp +++ b/examples/cpp/src/main.cpp @@ -1,6 +1,4 @@ - -#define OBX_CPP_FILE - +#define OBX_CPP_FILE #include "objectbox.hpp" @@ -24,7 +22,7 @@ int main(int argc, char* args[]) box.put(*task); // Update } - printf("Your task has ID=%llu, text=%s\n", + printf("Your task has ID=%" PRIu64 ", text=%s\n", id, box.get(id)->text.c_str());