1 #ifndef incl_HPHP_PARSE_TIME_FATAL_EXCEPTION_H
2 #define incl_HPHP_PARSE_TIME_FATAL_EXCEPTION_H
4 #include "hphp/util/exception.h"
7 /////////////////////////////////////////////////////////////////////////////
9 struct ParseTimeFatalException
: Exception
{
10 ParseTimeFatalException(const std::string
& file
, int line
,
11 ATTRIBUTE_PRINTF_STRING
const char* msg
, ...) ATTRIBUTE_PRINTF(4,5)
12 : m_file(file
), m_line(line
), m_parseFatal(true) {
13 va_list ap
; va_start(ap
, msg
); format(msg
, ap
); va_end(ap
);
16 EXCEPTION_COMMON_IMPL(ParseTimeFatalException
);
18 void setParseFatal(bool b
= true) { m_parseFatal
= b
; }
25 /////////////////////////////////////////////////////////////////////////////
27 #endif // incl_HPHP_PARSE_TIME_FATAL_EXCEPTION_H