aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/semantics.c
diff options
context:
space:
mode:
authorMark Mitchell <mark@codesourcery.com>2001-02-16 08:03:23 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>2001-02-16 08:03:23 +0000
commit8853373c4e042132909d083602beb51fde2ab17a (patch)
tree015f3f8aa9dd20334fd261fe2ef8dac89f382b87 /gcc/cp/semantics.c
parentb60ecc04e87b9ca4aaa6c79f46800cc3cf49d3d7 (diff)
downloadgcc-8853373c4e042132909d083602beb51fde2ab17a.zip
gcc-8853373c4e042132909d083602beb51fde2ab17a.tar.gz
gcc-8853373c4e042132909d083602beb51fde2ab17a.tar.bz2
pt.c (push_template_decl_real): Don't remangle the name of a class template.
* pt.c (push_template_decl_real): Don't remangle the name of a class template. From-SVN: r39753
Diffstat (limited to 'gcc/cp/semantics.c')
-rw-r--r--gcc/cp/semantics.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c
index c5bbe1b..9bd7ff7 100644
--- a/gcc/cp/semantics.c
+++ b/gcc/cp/semantics.c
@@ -912,7 +912,22 @@ finish_asm_stmt (cv_qualifier, string, output_operands,
if (!processing_template_decl)
for (t = input_operands; t; t = TREE_CHAIN (t))
- TREE_VALUE (t) = decay_conversion (TREE_VALUE (t));
+ {
+ tree converted_operand
+ = decay_conversion (TREE_VALUE (t));
+
+ /* If the type of the operand hasn't been determined (e.g.,
+ because it involves an overloaded function), then issue an
+ error message. There's no context available to resolve the
+ overloading. */
+ if (TREE_TYPE (converted_operand) == unknown_type_node)
+ {
+ cp_error ("type of asm operand `%E' could not be determined",
+ TREE_VALUE (t));
+ converted_operand = error_mark_node;
+ }
+ TREE_VALUE (t) = converted_operand;
+ }
r = build_stmt (ASM_STMT, cv_qualifier, string,
output_operands, input_operands,