summaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
authornathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-09-01 09:32:26 +0000
committernathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2000-09-01 09:32:26 +0000
commit7cdfe1ce8b20c6392726b5e2a9544c977f155f8e (patch)
tree64dab252919997752d59a0eee14734f9b4787a22 /gcc/cp
parent0c7e3476593469c87e564344bef30ecab4306841 (diff)
downloadgcc-7cdfe1ce8b20c6392726b5e2a9544c977f155f8e.tar.gz
* call.c (build_scoped_method_call): Check it is not a namespace.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@36094 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog4
-rw-r--r--gcc/cp/call.c5
2 files changed, 9 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 033185e4021..402c873fa0e 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,7 @@
+2000-09-01 Nathan Sidwell <nathan@codesourcery.com>
+
+ * call.c (build_scoped_method_call): Check it is not a namespace.
+
2000-08-30 Jason Merrill <jason@redhat.com>
* cp-tree.h (LOCAL_CLASS_P): Use decl_function_context.
diff --git a/gcc/cp/call.c b/gcc/cp/call.c
index 9c2b295dbb5..ff72fc8d1a0 100644
--- a/gcc/cp/call.c
+++ b/gcc/cp/call.c
@@ -275,6 +275,11 @@ build_scoped_method_call (exp, basetype, name, parms)
}
}
+ if (TREE_CODE (basetype) == NAMESPACE_DECL)
+ {
+ cp_error ("`%D' is a namespace", basetype);
+ return error_mark_node;
+ }
if (! is_aggr_type (basetype, 1))
return error_mark_node;