aboutsummaryrefslogtreecommitdiff
path: root/gcc/d/d-attribs.cc
diff options
context:
space:
mode:
authorJerry DeLisle <jvdelisle@gcc.gnu.org>2025-09-02 15:58:26 -0700
committerJerry DeLisle <jvdelisle@gcc.gnu.org>2025-09-02 15:58:26 -0700
commit071b4126c613881f4cb25b4e5c39032964827f88 (patch)
tree7ed805786566918630d1d617b1ed8f7310f5fd8e /gcc/d/d-attribs.cc
parent845d23f3ea08ba873197c275a8857eee7edad996 (diff)
parentcaa1c2f42691d68af4d894a5c3e700ecd2dba080 (diff)
downloadgcc-devel/gfortran-test.zip
gcc-devel/gfortran-test.tar.gz
gcc-devel/gfortran-test.tar.bz2
Merge branch 'master' into gfortran-testdevel/gfortran-test
Diffstat (limited to 'gcc/d/d-attribs.cc')
-rw-r--r--gcc/d/d-attribs.cc9
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/d/d-attribs.cc b/gcc/d/d-attribs.cc
index 77315dc..53aea5e 100644
--- a/gcc/d/d-attribs.cc
+++ b/gcc/d/d-attribs.cc
@@ -1406,7 +1406,7 @@ d_handle_no_sanitize_attribute (tree *node, tree name, tree args, int,
return NULL_TREE;
}
- unsigned int flags = 0;
+ sanitize_code_type flags = 0;
for (; args; args = TREE_CHAIN (args))
{
tree id = TREE_VALUE (args);
@@ -1424,16 +1424,17 @@ d_handle_no_sanitize_attribute (tree *node, tree name, tree args, int,
merge existing flags if no_sanitize was previously handled. */
if (tree attr = lookup_attribute ("no_sanitize", DECL_ATTRIBUTES (*node)))
{
- unsigned int old_value = tree_to_uhwi (TREE_VALUE (attr));
+ sanitize_code_type old_value =
+ tree_to_sanitize_code_type (TREE_VALUE (attr));
flags |= old_value;
if (flags != old_value)
- TREE_VALUE (attr) = build_int_cst (d_uint_type, flags);
+ TREE_VALUE (attr) = build_int_cst (d_ulong_type, flags);
}
else
{
DECL_ATTRIBUTES (*node) = tree_cons (get_identifier ("no_sanitize"),
- build_int_cst (d_uint_type, flags),
+ build_int_cst (d_ulong_type, flags),
DECL_ATTRIBUTES (*node));
}