From c47d0905a91442cb4532b901e1cd24129600a4a4 Mon Sep 17 00:00:00 2001 From: Marc Gilleron Date: Sat, 11 Jul 2020 02:52:22 +0100 Subject: [PATCH] Fix missing file --- util/macros.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 util/macros.h diff --git a/util/macros.h b/util/macros.h new file mode 100644 index 00000000..388e98f1 --- /dev/null +++ b/util/macros.h @@ -0,0 +1,13 @@ +#ifndef VOXEL_MACROS_H +#define VOXEL_MACROS_H + +#include + +// print_verbose() is used everywhere in the engine, but its drawback is that even if you turn it off, strings +// you print are still allocated and formatted, to not be used. This macro avoids the string. +#define PRINT_VERBOSE(msg) \ + if (OS::get_singleton()->is_stdout_verbose()) { \ + print_line(msg); \ + } + +#endif // VOXEL_MACROS_H