Commit a9f0423f by Jason Merrill Committed by Jason Merrill

re PR c++/65046 (-Wabi-tag doesn't warn about variables or function return types)

	PR c++/65046
	* cp-tree.h (NAMESPACE_IS_INLINE): Remove.
	* parser.c (cp_parser_namespace_definition): Don't set it.
	* name-lookup.c (handle_namespace_attrs): Check
	DECL_NAMESPACE_ASSOCIATIONS instead.

From-SVN: r221642
parent 4b7c558d
2015-03-24 Jason Merrill <jason@redhat.com>
PR c++/65046
* cp-tree.h (NAMESPACE_IS_INLINE): Remove.
* parser.c (cp_parser_namespace_definition): Don't set it.
* name-lookup.c (handle_namespace_attrs): Check
DECL_NAMESPACE_ASSOCIATIONS instead.
PR c++/65498
* pt.c (get_mostly_instantiated_function_type): Just return the
type of the partially instantiated template in DECL_TI_TEMPLATE.
......
......@@ -152,7 +152,6 @@ c-common.h, not after.
DECL_MUTABLE_P (in FIELD_DECL)
DECL_DEPENDENT_P (in USING_DECL)
LABEL_DECL_BREAK (in LABEL_DECL)
NAMESPACE_IS_INLINE (in NAMESPACE_DECL)
1: C_TYPEDEF_EXPLICITLY_SIGNED (in TYPE_DECL).
DECL_TEMPLATE_INSTANTIATED (in a VAR_DECL or a FUNCTION_DECL)
DECL_MEMBER_TEMPLATE_P (in TEMPLATE_DECL)
......@@ -2657,10 +2656,6 @@ struct GTY(()) lang_decl {
#define LOCAL_CLASS_P(NODE) \
(decl_function_context (TYPE_MAIN_DECL (NODE)) != NULL_TREE)
/* 1 iff this NAMESPACE_DECL is an inline namespace. */
#define NAMESPACE_IS_INLINE(NODE) \
DECL_LANG_FLAG_0 (NAMESPACE_DECL_CHECK (NODE))
/* For a NAMESPACE_DECL: the list of using namespace directives
The PURPOSE is the used namespace, the value is the namespace
that is the common ancestor. */
......
......@@ -3657,7 +3657,7 @@ handle_namespace_attrs (tree ns, tree attributes)
}
else if (is_attribute_p ("abi_tag", name))
{
if (!NAMESPACE_IS_INLINE (ns))
if (!DECL_NAMESPACE_ASSOCIATIONS (ns))
{
warning (OPT_Wattributes, "ignoring %qD attribute on non-inline "
"namespace", name);
......
......@@ -16233,7 +16233,6 @@ cp_parser_namespace_definition (cp_parser* parser)
if (is_inline)
{
tree name_space = current_namespace;
NAMESPACE_IS_INLINE (name_space) = true;
/* Set up namespace association. */
DECL_NAMESPACE_ASSOCIATIONS (name_space)
= tree_cons (CP_DECL_CONTEXT (name_space), NULL_TREE,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment