diff --git a/include/spdlog/common.h b/include/spdlog/common.h index 1269c14a..26d3708e 100644 --- a/include/spdlog/common.h +++ b/include/spdlog/common.h @@ -319,7 +319,7 @@ struct source_loc { line{line_in}, funcname{funcname_in} {} - SPDLOG_CONSTEXPR bool empty() const SPDLOG_NOEXCEPT { return line == 0; } + SPDLOG_CONSTEXPR bool empty() const SPDLOG_NOEXCEPT { return line <= 0; } const char *filename{nullptr}; int line{0}; const char *funcname{nullptr};