check.cpp
来自「一个实现C++反射机制的类库」· C++ 代码 · 共 53 行
CPP
53 行
/******************************************************************************\* ** @.cpp ** ** <Purpose of this file> ** *\******************************************************************************/// $Id: check.cpp,v 1.1 2007/10/25 14:05:27 tdevadit Exp $#include "check.hpp"#include <stdlib.h>#include <stdio.h>namespace reflcpp {voidcheckFail(const char *type, const char *e, const char *f, int line) { fprintf(stderr, "%s failed in %s at line %d: %s.\n", type, f, line, e); #ifdef IXCR_LINUX // On Linux, getting core dumps from threaded processes is a pain. If // the thread is not the "main" thread, it doesn't dump core. The // workaround is to fork first to create a process with just the // aborting thread, then abort. if (fork() == 0) { // Child abort(); } else { // Parent exit(1); } #else abort(); #endif}static const char check_cpp_id[] ="$Id: check.cpp,v 1.1 2007/10/25 14:05:27 tdevadit Exp $";} // namespace
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?