Commit Graph

12 Commits

Author SHA1 Message Date
Deadbeef
daff015314 Migrate tests to use -Znext-solver 2024-06-30 17:08:45 +00:00
Deadbeef
81da6a6d40 Make effects an incomplete feature 2024-06-22 14:11:11 +00:00
Ralf Jung
d94f6576dd extend doc comment for reachability set computation
also extend the const fn reachability test
2024-03-25 19:57:57 +01:00
bors
3b85d2c7fc Auto merge of #121644 - oli-obk:unique_static_innards2, r=RalfJung,nnethercote
Ensure nested allocations in statics neither get deduplicated nor duplicated

This PR generates new `DefId`s for nested allocations in static items and feeds all the right queries to make the compiler believe these are regular `static` items. I chose this design, because all other designs are fragile and make the compiler horribly complex for such a niche use case.

At present this wrecks incremental compilation performance *in case nested allocations exist* (because any query creating a `DefId` will be recomputed and never loaded from the cache). This will be resolved later in https://github.com/rust-lang/rust/pull/115613 . All other statics are unaffected by this change and will not have performance regressions (heh, famous last words)

This PR contains various smaller refactorings that can be pulled out into separate PRs. It is best reviewed commit-by-commit. The last commit is where the actual magic happens.

r? `@RalfJung` on the const interner and engine changes

fixes https://github.com/rust-lang/rust/issues/79738
2024-03-12 10:29:15 +00:00
Amanjeev Sethi
0a2475c50a Add tests showing how we duplicate allocations when we shouldn't 2024-03-12 05:50:10 +00:00
Michael Goulet
f614eaea2c Remove some unnecessary allow(incomplete_features) 2024-03-11 19:42:04 +00:00
Deadbeef
e4f237d39e bless ui tests 2023-12-19 04:28:21 +00:00
Nilstrieb
c63b6a437e Rip it out
My type ascription
Oh rip it out
Ah
If you think we live too much then
You can sacrifice diagnostics
Don't mix your garbage
Into my syntax
So many weird hacks keep diagnostics alive
Yet I don't even step outside
So many bad diagnostics keep tyasc alive
Yet tyasc doesn't even bother to survive!
2023-05-01 16:15:13 +08:00
Michael Goulet
24c2c075cc Encode lifetime param spans too 2023-04-22 01:13:54 +00:00
Michael Goulet
1ee189cde5 Encode def span for ConstParam 2023-04-17 02:57:23 +00:00
Michael Goulet
3a4fdcf86c Encode const mir for closures if they're const 2023-01-16 14:59:27 +00:00
Albert Larsan
cf2dff2b1e
Move /src/test to /tests 2023-01-11 09:32:08 +00:00