Commit 924f7b84 authored by deanm@chromium.org's avatar deanm@chromium.org

In release, disable UNREACHABLE and make UNIMPLEMENTED and FATAL simpler,...

In release, disable UNREACHABLE and make UNIMPLEMENTED and FATAL simpler, removing the file name and line numbers, so we carry around less data and can share more code.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@353 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 8c7550f9
......@@ -37,14 +37,20 @@ void API_Fatal(const char* location, const char* format, ...);
// The FATAL, UNREACHABLE and UNIMPLEMENTED macros are useful during
// development, but they should not be relied on in the final product.
#ifdef DEBUG
#define FATAL(msg) \
V8_Fatal(__FILE__, __LINE__, "%s", (msg))
#define UNIMPLEMENTED() \
V8_Fatal(__FILE__, __LINE__, "unimplemented code")
#define UNREACHABLE() \
V8_Fatal(__FILE__, __LINE__, "unreachable code")
#else
#define FATAL(msg) \
V8_Fatal("", 0, "%s", (msg))
#define UNIMPLEMENTED() \
V8_Fatal(__FILE__, __LINE__, "unimplemented code")
V8_Fatal("", 0, "unimplemented code")
#define UNREACHABLE() ((void) 0)
#endif
// Used by the CHECK macro -- should not be called directly.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment