diff --git a/src/core/include/megbrain/utils/metahelper.h b/src/core/include/megbrain/utils/metahelper.h index b9909b149974efee4b51b609c8383938c0a792bc..b44d528820864af8442f46b1ec26912de0f38101 100644 --- a/src/core/include/megbrain/utils/metahelper.h +++ b/src/core/include/megbrain/utils/metahelper.h @@ -122,7 +122,7 @@ class DynTypeObj { //! get class name from class object #define _MGB_TYPEINFO_CLASS_NAME(_cls) #_cls #else -#define _MGB_TYPEINFO_CLASS_NAME(_cls) nullptr +#define _MGB_TYPEINFO_CLASS_NAME(_cls) "" #endif //! put in the impl file of a class that needs static typeinfo() diff --git a/src/plugin/test/opr_io_dump.cpp b/src/plugin/test/opr_io_dump.cpp index 78d65e68458b4d24ee9b05f5e2cb3e4f2e228ab9..3b05ceb67f2a8673080f027369e1204e5fcbcc88 100644 --- a/src/plugin/test/opr_io_dump.cpp +++ b/src/plugin/test/opr_io_dump.cpp @@ -147,7 +147,7 @@ std::vector getlines(std::istream& inp, size_t skip_head = 0) { } } // anonymous namespace - +#if MGB_VERBOSE_TYPEINFO_NAME TEST(TestOprIODump, Text) { auto fname_base = output_file("test_opr_iodump"); std::array fnames; @@ -180,8 +180,10 @@ TEST(TestOprIODump, Text) { run_test(make_plugin, check_result); } +#endif TEST(TestOprIODump, StdErr) { + MGB_MARK_USED_VAR(EXPECTED_TEXT_OUT_REC); HostTensorGenerator<> gen; auto host_x = gen({5}); auto host_y = gen({5});