mergerfs/src/die.hpp

14 lines
587 B
C++
Raw Normal View History

2025-11-21 13:43:09 -06:00
#pragma once
#include "fmt/core.h"
2025-11-21 13:47:53 -06:00
#include <cstdlib>
2025-11-21 13:43:09 -06:00
2025-11-21 13:47:53 -06:00
#define DIE(...) \
do { \
fmt::print(stderr, fmt::emphasis::bold | fg(fmt::color::red), \
"{}:{} in {}: ", __FILE__, __LINE__, __func__); \
fmt::print(stderr, __VA_ARGS__); \
fmt::print(stderr, "\n"); \
std::abort(); \
} while(0)