1#ifndef ROSE_PROCESSSUPPORT_H
2#define ROSE_PROCESSSUPPORT_H
9#include <Sawyer/Assert.h>
14#include <ROSE_ABORT.h>
15#include <ROSE_ASSERT.h>
17ROSE_UTIL_API
int systemFromVector(
const std::vector<std::string>& argv);
18FILE* popenReadFromVector(
const std::vector<std::string>& argv);
20int pcloseFromVector(FILE* f);
28ROSE_UTIL_API
void abortOnFailedAssertion(
const char*,
const char*,
const std::string&,
const char*,
unsigned,
const char*);
31ROSE_UTIL_API
void exitOnFailedAssertion(
const char*,
const char*,
const std::string&,
const char*,
unsigned,
const char*);
36ROSE_UTIL_API
void throwOnFailedAssertion(
const char*,
const char*,
const std::string&,
const char*,
unsigned,
const char*);
60 const char *functionName;
61 FailedAssertion(
const char *mesg,
const char *expr,
const std::string ¬e,
62 const char *fileName,
unsigned lineNumber,
const char *functionName)
63 : std::runtime_error(expr?expr:mesg), mesg(mesg), expr(expr), note(note), fileName(fileName),
64 lineNumber(lineNumber), functionName(functionName) {}
Sawyer::Assert::AssertFailureHandler failedAssertionBehavior()
Property: behavior of failed assertions.
ROSE_UTIL_API void abortOnFailedAssertion(const char *, const char *, const std::string &, const char *, unsigned, const char *)
Aborts for a failed assertion.
ROSE_UTIL_API void throwOnFailedAssertion(const char *, const char *, const std::string &, const char *, unsigned, const char *)
Throws an exception for a failed assertion.
ROSE_UTIL_API void exitOnFailedAssertion(const char *, const char *, const std::string &, const char *, unsigned, const char *)
Exits with non-zero status for a failed assertion.
void(* AssertFailureHandler)(const char *mesg, const char *expr, const std::string ¬e, const char *filename, unsigned linenum, const char *funcname)
Type for user-defined assertion failure handler.
Exception that can be thrown for a failed assertion.