aboutsummaryrefslogtreecommitdiff
path: root/gold/gold.h
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@google.com>2006-11-29 17:56:40 +0000
committerIan Lance Taylor <iant@google.com>2006-11-29 17:56:40 +0000
commita3ad94edd406b9abc26493761764d4034dda69fa (patch)
tree96485e8bba91a4aa51f34b0d3738ef3e7ddcbac3 /gold/gold.h
parente1da3f5b9645750e966e471ff0db480d6450dcb7 (diff)
downloadgdb-a3ad94edd406b9abc26493761764d4034dda69fa.zip
gdb-a3ad94edd406b9abc26493761764d4034dda69fa.tar.gz
gdb-a3ad94edd406b9abc26493761764d4034dda69fa.tar.bz2
Hash tables, dynamic section, i386 PLT, gold_assert.
Diffstat (limited to 'gold/gold.h')
-rw-r--r--gold/gold.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/gold/gold.h b/gold/gold.h
index d55d1f6..78c106f 100644
--- a/gold/gold.h
+++ b/gold/gold.h
@@ -163,10 +163,18 @@ gold_fatal(const char* msg, bool perrno) ATTRIBUTE_NORETURN;
extern void
gold_nomem() ATTRIBUTE_NORETURN;
-// This function is called in cases which can not arise if the code is
-// written correctly.
-extern void
-gold_unreachable() ATTRIBUTE_NORETURN;
+// This macro and function are used in cases which can not arise if
+// the code is written correctly.
+
+#define gold_unreachable() \
+ (gold::do_gold_unreachable(__FILE__, __LINE__, __FUNCTION__))
+
+extern void do_gold_unreachable(const char*, int, const char*)
+ ATTRIBUTE_NORETURN;
+
+// Assertion check.
+
+#define gold_assert(expr) ((void)(!(expr) ? gold_unreachable(), 0 : 0))
// Queue up the first set of tasks.
extern void