summaryrefslogtreecommitdiff
path: root/gcc/unwind-pe.h
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2005-05-19 17:59:02 -0700
committerRichard Henderson <rth@gcc.gnu.org>2005-05-19 17:59:02 -0700
commite4d0c41cba2de3018b63bf9a9e1041500d03936c (patch)
treef4bcc1acb88a25452bc8ab90dadd3a945af293b6 /gcc/unwind-pe.h
parent65869a72a6fb4b3c102615b7c0c30f8e0ef2388b (diff)
downloadgcc-e4d0c41cba2de3018b63bf9a9e1041500d03936c.tar.gz
* unwind.h, unwind-pe.h: Revert gcc_unreachable change of 05-17.
From-SVN: r100001
Diffstat (limited to 'gcc/unwind-pe.h')
-rw-r--r--gcc/unwind-pe.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/gcc/unwind-pe.h b/gcc/unwind-pe.h
index ce7d6943c0a..398165749a5 100644
--- a/gcc/unwind-pe.h
+++ b/gcc/unwind-pe.h
@@ -34,6 +34,13 @@
#ifndef GCC_UNWIND_PE_H
#define GCC_UNWIND_PE_H
+/* If using C++, references to abort have to be qualified with std::. */
+#if __cplusplus
+#define __gxx_abort std::abort
+#else
+#define __gxx_abort abort
+#endif
+
/* Pointer encodings, from dwarf2.h. */
#define DW_EH_PE_absptr 0x00
#define DW_EH_PE_omit 0xff
@@ -79,9 +86,8 @@ size_of_encoded_value (unsigned char encoding)
return 4;
case DW_EH_PE_udata8:
return 8;
- default:
- gcc_unreachable ();
}
+ __gxx_abort ();
}
#endif
@@ -112,9 +118,8 @@ base_of_encoded_value (unsigned char encoding, struct _Unwind_Context *context)
return _Unwind_GetDataRelBase (context);
case DW_EH_PE_funcrel:
return _Unwind_GetRegionStart (context);
- default:
- gcc_unreachable ();
}
+ __gxx_abort ();
}
#endif
@@ -251,7 +256,7 @@ read_encoded_value_with_base (unsigned char encoding, _Unwind_Ptr base,
break;
default:
- gcc_unreachable ();
+ __gxx_abort ();
}
if (result != 0)