diff options
author | Philip Herron <herron.philip@googlemail.com> | 2025-04-16 17:13:04 +0100 |
---|---|---|
committer | Philip Herron <philip.herron@embecosm.com> | 2025-04-16 22:19:17 +0000 |
commit | 50a90f12af84ba2d203a0510bbeb41a383981303 (patch) | |
tree | a4c06682ba956ea97f742ab1fd4dd3379d686a7e /gcc/rust/ast/rust-expr.h | |
parent | 95615a1ab48f1493fef21bb9f5f465f02ff527e4 (diff) | |
download | gcc-50a90f12af84ba2d203a0510bbeb41a383981303.zip gcc-50a90f12af84ba2d203a0510bbeb41a383981303.tar.gz gcc-50a90f12af84ba2d203a0510bbeb41a383981303.tar.bz2 |
gccrs: Fix ICE when checking shift's which are behind array refs
I copied a bad form of this check from the c front-end this updates it
to ensure the rhs is an INTEGER_CST and the lhs needs checked in the first
place.
Fixes Rust-GCC#3664
gcc/rust/ChangeLog:
* rust-gcc.cc (arithmetic_or_logical_expression): Ensure this is an integer
gcc/testsuite/ChangeLog:
* rust/compile/issue-3664.rs: New test.
Signed-off-by: Philip Herron <herron.philip@googlemail.com>
Diffstat (limited to 'gcc/rust/ast/rust-expr.h')
0 files changed, 0 insertions, 0 deletions