rustbot
added
A-attributes
labels
rust-bors
Bot
added
S-waiting-on-author
and removed S-waiting-on-bors
labels
rust-bors
Bot
added
S-waiting-on-bors
and removed S-waiting-on-author
labels
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request
Add very basic "comptime" fn implementation Implements functions that cannot be called at runtime (and thus also not from normal const functions, as those could be called from runtime). This is done via the internal attribute `rustc_comptime` that can be added to normal functions, turning them into compile-time-only functions. Because @fee1-dead and @compiler-errors did amazing work, we even get trait bounds that work inside comptime fns: via unconditionally-const `const Trait` bounds. Use cases are * rust-lang#146923 * const heap intrinsics * and the other various intrinsics (e.g. size_of 😆) that will just ICE in codegen or panic at runtime if they actually end up in runtime code project goal issue: rust-lang/rust-project-goals#406 no tracking issue until we have a feature gate and some sort of syntax cc @scottmcm as the T-lang goal champion
This was referenced
rust-bors Bot pushed a commit that referenced this pull request
…uwer Rollup of 13 pull requests Successful merges: - #147302 (asm! support for the Xtensa architecture) - #148820 (Add very basic "comptime" fn implementation) - #157299 (Fix unstable diagnostics in tests) - #143511 (Improve TLS codegen by marking the panic/init path as cold) - #154608 (Add `_value` API for number literals in proc-macro) - #156762 (xfs support in `test_rename_directory_to_non_empty_directory`) - #157300 (Relax test requirements for consistency) - #157383 (tests: codegen-llvm: Ignore BPF targets in c-variadic-opt) - #157413 (fix: don't suggest .into_iter() for .cloned()/.copied() on non-reference Option) - #157578 (Fix diagnostics for non-exhaustive destructuring assignments (#157553)) - #157587 (explain that the size_of constant also serves to avoid optimizing away 'unused' size_of calls) - #157596 (test: remove ineffective link-extern-crate-with-drop-type test) - #157602 (rustdoc: Remove unnecessary fast path)
rust-timer added a commit that referenced this pull request
Rollup merge of #148820 - oli-obk:comptime, r=fee1-dead Add very basic "comptime" fn implementation Implements functions that cannot be called at runtime (and thus also not from normal const functions, as those could be called from runtime). This is done via the internal attribute `rustc_comptime` that can be added to normal functions, turning them into compile-time-only functions. Because @fee1-dead and @compiler-errors did amazing work, we even get trait bounds that work inside comptime fns: via unconditionally-const `const Trait` bounds. Use cases are * #146923 * const heap intrinsics * and the other various intrinsics (e.g. size_of 😆) that will just ICE in codegen or panic at runtime if they actually end up in runtime code project goal issue: rust-lang/rust-project-goals#406 no tracking issue until we have a feature gate and some sort of syntax cc @scottmcm as the T-lang goal champion
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
rust-bors Bot pushed a commit that referenced this pull request
Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to #148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
jhpratt added a commit to jhpratt/rust that referenced this pull request
…e1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to rust-lang#148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.
rust-timer added a commit that referenced this pull request
Rollup merge of #157647 - oli-obk:start-using-comptime, r=fee1-dead Start using comptime for reflection intrinsics and their wrapper functions r? @fee1-dead follow-up to #148820 I needed to add some more rustc code because turns out I forgot to add tests to the previous PR which actually codegen while using comptime fns. Check builds never try to create optimized MIR, so no code ever hit the assert that prevents creating optimized MIR for comptime fns.