Apache Mesos
Macros | Functions
abort.hpp File Reference
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <string>
#include <stout/attributes.hpp>

Go to the source code of this file.

Macros

#define __STRINGIZE(x)   #x
 
#define _STRINGIZE(x)   __STRINGIZE(x)
 
#define _ABORT_PREFIX   "ABORT: (" __FILE__ ":" _STRINGIZE(__LINE__) "): "
 
#define ABORT(...)   _Abort(_ABORT_PREFIX, __VA_ARGS__)
 

Functions

STOUT_NORETURN void _Abort (const char *prefix, const char *message)
 
STOUT_NORETURN void _Abort (const char *prefix, const std::string &message)
 

Macro Definition Documentation

#define __STRINGIZE (   x)    #x
#define _ABORT_PREFIX   "ABORT: (" __FILE__ ":" _STRINGIZE(__LINE__) "): "
#define _STRINGIZE (   x)    __STRINGIZE(x)
#define ABORT (   ...)    _Abort(_ABORT_PREFIX, __VA_ARGS__)

Function Documentation

STOUT_NORETURN void _Abort ( const char *  prefix,
const char *  message 
)
inline
STOUT_NORETURN void _Abort ( const char *  prefix,
const std::string &  message 
)
inline