[libiberty] Update demangler to handle co_await operator.
authorIain Sandoe <iain@sandoe.co.uk>
Wed, 4 Dec 2019 11:39:38 +0000 (11:39 +0000)
committerIain Sandoe <iain@sandoe.co.uk>
Sat, 18 Jan 2020 12:15:12 +0000 (12:15 +0000)
C++20 coroutines introduces a new operator with a mangling of 'aw'.
This patch adds that to libiberty's demangler.

libiberty/ChangeLog:

2020-01-18  Iain Sandoe  <iain@sandoe.co.uk>

* cp-demangle.c (cplus_demangle_operators): Add the co_await
operator.
* testsuite/demangle-expected: Test co_await operator mangling.

libiberty/cp-demangle.c
libiberty/testsuite/demangle-expected

index 3639bfb..fc55b7f 100644 (file)
@@ -1802,6 +1802,7 @@ const struct demangle_operator_info cplus_demangle_operators[] =
   { "ad", NL ("&"),         1 },
   { "an", NL ("&"),         2 },
   { "at", NL ("alignof "),   1 },
+  { "aw", NL ("co_await "), 1 },
   { "az", NL ("alignof "),   1 },
   { "cc", NL ("const_cast"), 2 },
   { "cl", NL ("()"),        2 },
index 5878d96..daffe78 100644 (file)
@@ -1450,3 +1450,6 @@ Foo<int>()::{lambda(auto:1)#1}::operator()<char>(char) const::X::fn
 
 _Z3fooILPv0EEvPN9enable_ifIXeqT_LDnEEvE4typeE
 void foo<(void*)0>(enable_if<((void*)0)==((decltype(nullptr))), void>::type*)
+
+_ZNK5coro15emptyawEv
+coro1::empty::operator co_await() const