diff options
author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2023-09-08 15:40:28 +0200 |
---|---|---|
committer | Arthur Cohen <arthur.cohen@embecosm.com> | 2024-01-16 19:04:35 +0100 |
commit | f538c29d78646c060e391770b6e5e821b99c7685 (patch) | |
tree | 50136a9d37b06f382e161d5ca0b4ae1fde1c460e /gcc/rust/backend/rust-compile-intrinsic.cc | |
parent | 15648d5b8dc5a8cab1b11e14e5e5c178e32ed366 (diff) | |
download | gcc-f538c29d78646c060e391770b6e5e821b99c7685.zip gcc-f538c29d78646c060e391770b6e5e821b99c7685.tar.gz gcc-f538c29d78646c060e391770b6e5e821b99c7685.tar.bz2 |
gccrs: Shorten `make_unsigned_long_tree` code and remove `Backend::integer_constant_expression`
gcc/rust/ChangeLog:
* backend/rust-compile-intrinsic.cc: Simplify `make_unsigned_long_tree`
* rust-backend.h: Remove `integer_constant_expression`
* rust-gcc.cc: Remove `integer_constant_expression`
Diffstat (limited to 'gcc/rust/backend/rust-compile-intrinsic.cc')
-rw-r--r-- | gcc/rust/backend/rust-compile-intrinsic.cc | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/gcc/rust/backend/rust-compile-intrinsic.cc b/gcc/rust/backend/rust-compile-intrinsic.cc index 2f8bc49..243aab7 100644 --- a/gcc/rust/backend/rust-compile-intrinsic.cc +++ b/gcc/rust/backend/rust-compile-intrinsic.cc @@ -736,10 +736,7 @@ copy_nonoverlapping_handler (Context *ctx, TyTy::FnType *fntype) static tree make_unsigned_long_tree (unsigned long value) { - mpz_t mpz_value; - mpz_init_set_ui (mpz_value, value); - - return Backend::integer_constant_expression (integer_type_node, mpz_value); + return build_int_cst (integer_type_node, value); } static tree |