-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ICE: empty struct + extern function on 32-bit OS #16441
Comments
The reason for this seems to be that we mark zero-sized structs as cc @dotdash any opinions on this? |
I just checked with clang, and it always ignores empty structs (tried i686, x86_64, mips and arm targets), though it doesn't seem to affect the generated asm whether or not the argument is present, as long as it's passed as a direct argument (only tried on i686 and x86_64). The problem we had before, which was resolved by introducing the "Ignore" arg kind by @klutzy was that like all structs, the empty struct was passed as an indirect argument on x86. And that messed up the ffi since it used stack space. It's a bit sad, since it complicates things, but I guess we should be doing the same as clang here and simply ignore empty structs. Maybe it can be done a bit easier if we make it so that it's not platform specific but done for all foreign functions? |
…kril feat: enable excluding refs search results in test ## Change Here I introduce a new `ReferenceCategory::Test` type to indicate whether the function where this reference is located is marked as `#[test]`, and expose an config item (`rust-analyzer.references.excludeTests`) to client. I also changed the signature of `ReferenceCategory::new`, adding a `sema: &Semantics<'_, RootDatabase>` param to do some hir analysis. Hope the current implementation is good to go. ## Demo `"rust-analyzer.references.excludeTests": false` ![include](https://github.com/rust-lang/rust-analyzer/assets/71162630/9f1176d4-7b41-4f49-ac79-55d25a42d5d1) `"rust-analyzer.references.excludeTests": true` ![exclude](https://github.com/rust-lang/rust-analyzer/assets/71162630/2938b44b-9e5b-48de-a049-453f5bbc09d0) close rust-lang/rust-analyzer#14530
with
--target=i686-unknown-linux-gnu
or--target=i686-pc-mingw32
:This causes #15811. (cc jeremyletang/rgtk#26)
The text was updated successfully, but these errors were encountered: