@@ -13210,6 +13210,7 @@ base_type_die (tree type, bool reverse)
{
const char *name = IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (type)));
if (strcmp (name, "char16_t") == 0
+ || strcmp (name, "char8_t") == 0
|| strcmp (name, "char32_t") == 0)
{
encoding = DW_ATE_UTF;
new file mode 100644
@@ -0,0 +1,9 @@
+// { dg-do compile { target c++20 } }
+// { dg-options { -gdwarf -dA } }
+
+// Test that all three use DW_ATE_UTF.
+// { dg-final { scan-assembler-times {DW_AT_encoding \(0x10\)} 3 } }
+
+char8_t c8;
+char16_t c16;
+char32_t c32;