Fix intrinsic error location#4502
Conversation
CohenArthur
left a comment
There was a problem hiding this comment.
The changes look good to me but there are a couple issues with the testsuite where error locations haven't been updated, e.g. rust/compile/torture/intrinsics-5.rs and rust/compile/torture/intrinsics-7.rs. But overall I'm happy with this and once it's fixed I'd like to get it merged :) Thank you!
64f7a4a to
9c25095
Compare
9c25095 to
d6a11ed
Compare
|
👋 It's supposed to be: you should have the list of all modified functions. The helper script should correctly provide you with a sensible skeleton. |
d6a11ed to
1cd4629
Compare
1cd4629 to
b89c63a
Compare
|
@dkm Could you please check the commit changelog and tell me if there are any other issues with it? |
b89c63a to
8ea2359
Compare
Yes, looks better thanks! Small comments though... You can group things like: And the idiomatic way of not copy/pasting the same text is to use And last one, you should end entries with a Thanks! |
8ea2359 to
3c44150
Compare
When an intrisic is used with an incorrect type, prin the location of the call site, not the declaration. Fixes Rust-GCC#4465. gcc/rust/ChangeLog: * backend/rust-intrinsic-handlers.cc (check_for_basic_integer_type): Fixed typo. (build_atomic_builtin_name): Update message. (unchecked_op, atomic_store, ctlz_handler) (cttz_handler, bswap_handler): Use call location. gcc/testsuite/ChangeLog: * rust/compile/bswap.rs: Update error location. * rust/compile/ctlz.rs: Likewise. * rust/compile/ctlz_nonzero.rs: Likewise. * rust/compile/cttz.rs: Likewise. * rust/compile/cttz_nonzero.rs: Likewise. * rust/compile/torture/intrinsics-5.rs: Likewise. * rust/compile/torture/intrinsics-7.rs: Likewise. Signed-off-by: Jean-Christian CÎRSTEA <jean-christian.cirstea@tuta.com>
3c44150 to
cbf980f
Compare
|
@dkm Updated the commit message. |
|
It looks great! Thank you! |
When an intrisic is used with an incorrect type, prin the location of
the call site, not the declaration.
Fixes #4465.
gcc/rust/ChangeLog:
gcc/testsuite/ChangeLog: