summaryrefslogtreecommitdiff
path: root/libstdc++-v3/testsuite/abi
diff options
context:
space:
mode:
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2010-01-10 00:24:52 +0000
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2010-01-10 00:24:52 +0000
commitdb80fc3f1add0d1d105ce7569fb6fbedebf40b7f (patch)
tree2b6609917b3fbd2025fcdb94fb3fac7f8b42e73b /libstdc++-v3/testsuite/abi
parent4f470a3bd4480b344b812d934574f55918305fe0 (diff)
downloadgcc-db80fc3f1add0d1d105ce7569fb6fbedebf40b7f.tar.gz
Return dgs.alc on success
libiberty/ 2010-01-09 Ian Lance Taylor <iant@google.com> PR other/42230 * cp-demangle.c (d_demangle): Return dgs.alc on success. libstdc++-v3/ 2010-01-09 H.J. Lu <hongjiu.lu@intel.com> PR other/42230 * testsuite/abi/pr42230.cc: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155785 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/testsuite/abi')
-rw-r--r--libstdc++-v3/testsuite/abi/pr42230.cc16
1 files changed, 16 insertions, 0 deletions
diff --git a/libstdc++-v3/testsuite/abi/pr42230.cc b/libstdc++-v3/testsuite/abi/pr42230.cc
new file mode 100644
index 00000000000..2a338995336
--- /dev/null
+++ b/libstdc++-v3/testsuite/abi/pr42230.cc
@@ -0,0 +1,16 @@
+// { dg-do run }
+
+#include <cxxabi.h>
+#include <cassert>
+#include <cstddef>
+
+int main()
+{
+ std::size_t length = 0;
+ int cc;
+
+ char* ret = abi::__cxa_demangle("e", 0, &length, &cc);
+
+ assert( (cc < 0 && !ret) || (ret && length) );
+ return 0;
+}