diff options
author | Ian Lance Taylor <iant@golang.org> | 2021-09-13 10:37:49 -0700 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2021-09-13 10:37:49 -0700 |
commit | e252b51ccde010cbd2a146485d8045103cd99533 (patch) | |
tree | e060f101cdc32bf5e520de8e5275db9d4236b74c /gcc/cp/ptree.c | |
parent | f10c7c4596dda99d2ee872c995ae4aeda65adbdf (diff) | |
parent | 104c05c5284b7822d770ee51a7d91946c7e56d50 (diff) | |
download | gcc-e252b51ccde010cbd2a146485d8045103cd99533.zip gcc-e252b51ccde010cbd2a146485d8045103cd99533.tar.gz gcc-e252b51ccde010cbd2a146485d8045103cd99533.tar.bz2 |
Merge from trunk revision 104c05c5284b7822d770ee51a7d91946c7e56d50.
Diffstat (limited to 'gcc/cp/ptree.c')
-rw-r--r-- | gcc/cp/ptree.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/gcc/cp/ptree.c b/gcc/cp/ptree.c index 95a4fdf..7f140f5 100644 --- a/gcc/cp/ptree.c +++ b/gcc/cp/ptree.c @@ -59,16 +59,16 @@ cxx_print_decl (FILE *file, tree node, int indent) bool need_indent = true; - if (TREE_CODE (node) == FUNCTION_DECL - || TREE_CODE (node) == VAR_DECL - || TREE_CODE (node) == TYPE_DECL - || TREE_CODE (node) == TEMPLATE_DECL - || TREE_CODE (node) == CONCEPT_DECL - || TREE_CODE (node) == NAMESPACE_DECL) + tree ntnode = STRIP_TEMPLATE (node); + if (TREE_CODE (ntnode) == FUNCTION_DECL + || TREE_CODE (ntnode) == VAR_DECL + || TREE_CODE (ntnode) == TYPE_DECL + || TREE_CODE (ntnode) == CONCEPT_DECL + || TREE_CODE (ntnode) == NAMESPACE_DECL) { unsigned m = 0; - if (DECL_LANG_SPECIFIC (node) && DECL_MODULE_IMPORT_P (node)) - m = get_importing_module (node, true); + if (DECL_LANG_SPECIFIC (ntnode) && DECL_MODULE_IMPORT_P (ntnode)) + m = get_importing_module (ntnode, true); if (const char *name = m == ~0u ? "" : module_name (m, true)) { @@ -78,7 +78,7 @@ cxx_print_decl (FILE *file, tree node, int indent) need_indent = false; } - if (DECL_LANG_SPECIFIC (node) && DECL_MODULE_PURVIEW_P (node)) + if (DECL_LANG_SPECIFIC (ntnode) && DECL_MODULE_PURVIEW_P (ntnode)) { if (need_indent) indent_to (file, indent + 3); @@ -171,6 +171,7 @@ cxx_print_type (FILE *file, tree node, int indent) return; case TYPE_PACK_EXPANSION: + print_node (file, "pattern", PACK_EXPANSION_PATTERN (node), indent + 4); print_node (file, "args", PACK_EXPANSION_EXTRA_ARGS (node), indent + 4); return; |