Skip to content

Commit 2427236

Browse files
committed
choosing a different flag for parm_used_in_post_p
1 parent 8b9af00 commit 2427236

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

gcc/cp/cp-tree.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -565,6 +565,7 @@ extern GTY(()) tree cp_global_trees[CPTI_MAX];
565565
DECL_SELF_REFERENCE_P (in a TYPE_DECL)
566566
DECL_INVALID_OVERRIDER_P (in a FUNCTION_DECL)
567567
DECL_UNINSTANIATED_TEMPLATE_FRIEND_P (in TEMPLATE_DECL)
568+
parm_used_in_post_p (in PARM_DECL)
568569
5: DECL_INTERFACE_KNOWN.
569570
6: DECL_THIS_STATIC (in VAR_DECL, FUNCTION_DECL or PARM_DECL)
570571
DECL_FIELD_IS_BASE (in FIELD_DECL)
@@ -9031,7 +9032,7 @@ inline void
90319032
set_parm_used_in_post (tree decl, bool constify = true)
90329033
{
90339034
gcc_checking_assert (TREE_CODE (decl) == PARM_DECL);
9034-
decl->base.public_flag = constify;
9035+
DECL_LANG_FLAG_4 (decl) = constify;
90359036
}
90369037

90379038
/* Test if PARM_DECL is ODR used in a postcondition. */
@@ -9040,7 +9041,7 @@ inline bool
90409041
parm_used_in_post_p (const_tree decl)
90419042
{
90429043
/* Check if this parameter is odr used within a function's postcondition */
9043-
return ((TREE_CODE (decl) == PARM_DECL) && decl->base.public_flag);
9044+
return ((TREE_CODE (decl) == PARM_DECL) && DECL_LANG_FLAG_4 (decl));
90449045
}
90459046

90469047
/* Inline bodies. */

gcc/tree-core.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1339,9 +1339,6 @@ struct GTY(()) tree_base {
13391339
EXPR_LOCATION_WRAPPER_P in
13401340
NON_LVALUE_EXPR, VIEW_CONVERT_EXPR
13411341
1342-
parm_used_in_postcondition_p in
1343-
PARM_DECL
1344-
13451342
13461343
private_flag:
13471344

0 commit comments

Comments
 (0)