{
bool subtime = timevar_cond_start (TV_NAME_LOOKUP);
do_push_to_top_level ();
+ gcc_checking_assert (!DECL_CONTEXT (x));
+ DECL_CONTEXT (x) = FROB_CONTEXT (global_namespace);
x = pushdecl_namespace_level (x);
do_pop_from_top_level ();
timevar_cond_stop (TV_NAME_LOOKUP, subtime);
{
bool subtime = timevar_cond_start (TV_NAME_LOOKUP);
do_push_to_top_level ();
+ gcc_checking_assert (!DECL_CONTEXT (x));
+ DECL_CONTEXT (x) = FROB_CONTEXT (global_namespace);
x = pushdecl_namespace_level (x);
cp_finish_decl (x, init, false, NULL_TREE, 0);
do_pop_from_top_level ();
tree type = cp_build_qualified_type (TREE_TYPE (expr), TYPE_QUAL_CONST);
decl = create_temporary_var (type);
+ DECL_CONTEXT (decl) = NULL_TREE;
TREE_STATIC (decl) = true;
DECL_DECLARED_CONSTEXPR_P (decl) = true;
TREE_READONLY (decl) = true;
DECL_NAME (decl) = name;
SET_DECL_ASSEMBLER_NAME (decl, name);
- DECL_CONTEXT (decl) = global_namespace;
comdat_linkage (decl);
if (!zero_init_p (type))
&& initializer_constant_valid_p (compound_literal, type))
{
tree decl = create_temporary_var (type);
+ DECL_CONTEXT (decl) = NULL_TREE;
DECL_INITIAL (decl) = compound_literal;
TREE_STATIC (decl) = 1;
if (literal_type_p (type) && CP_TYPE_CONST_NON_VOLATILE_P (type))