- 24 9月, 2020 17 次提交
-
-
由 LeSeulArtichaut 提交于
-
由 bors 提交于
Preserve doc-comments when generating queries Closes https://github.com/rust-lang/rust/issues/76812
-
由 bors 提交于
const_evaluatable_checked: extend predicate collection We now walk the hir instead of using `ty` so that we get better spans here, While I am still not completely sure if that's what we want in the end, it does seem a lot closer to the final goal than the previous version. We also look into type aliases (and use a `TypeVisitor` here), about which I am not completely sure, but we will see how well this works. We also look into fn decls, so the following should work now. ```rust fn test<T>() -> [u8; std::mem::size_of::<T>()] { [0; std::mem::size_of::<T>()] } ``` Additionally, we visit the optional trait and self type of impls. r? `@oli-obk`
-
由 bors 提交于
Move MiniSet to data_structures remove the need for T to be copy from MiniSet as was done for MiniMap MiniMap and MiniSet was added by https://github.com/rust-lang/rust/pull/72412 think that this can be used in https://github.com/rust-lang/rust/pull/68828
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 bors 提交于
Fix underflow when calculating the number of no-op jumps folded When removing unwinds to no-op blocks and folding jumps to no-op blocks, remove the unwind target first. Otherwise we cannot determine if target has been already folded or not. Previous implementation incorrectly assumed that all resume targets had been folded already, occasionally resulting in an underflow: ``` remove_noop_landing_pads: removed 18446744073709551613 jumps and 3 landing pads ```
-
由 bors 提交于
Stabilize intra-doc links Fixes https://github.com/rust-lang/rust/issues/43466 Thanks to the great work of `@jyn514` in getting the [cross-crate reexport issue](https://github.com/rust-lang/rust/issues/65983) in intra-rustdoc links fixed, I think we're now in a position to stabilize this feature. The tracking issue currently has two unresolved issues: - <s>behavior around doc(hidden): This is fixed in https://github.com/rust-lang/rust/pull/73365, which is just waiting for CI and should land tomorrow. It's also a pretty niche bug so while I expect it to land soon I don't think we need to block stabilization on it anyway.</s> - Non-identifier primitive types like slices: This was not a part of the original RFC anyway, and is a pretty niche use case The feature itself, sans https://github.com/rust-lang/rust/issues/65983, has been shipped on nightly for three years now, with people using it on docs.rs. https://github.com/rust-lang/rust/issues/65983 itself is not an overwhelmingly central bit of functionality; the reason we elected to block stabilization on it was that back in 2017 it was not possible to fix the issue without some major refactorings of resolve, and we did not want to stabilize something that had such a potentially unfixable bug. Given that we've fixed it, I see no reason to delay stabilization on this long awaited feature. It's possible that the latest patches have problems, however we _have_ done crater runs of some of the crucial parts. Furthermore, that's what the release trains are for, we will have a solid three months to let it ride the trains before it actually hits the stable compiler. r? `@rust-lang/rustdoc`
-
由 bors 提交于
revert const_type_id stabilization This reverts #72488, which is currently on beta and scheduled to stabilize in `1.47.0`, based on https://github.com/rust-lang/rust/pull/75923#issuecomment-696676511 It turns out we might not be quite ready to stabilize `TypeId` in const contexts before having a chance to rework its internals. Since `TypeId` is a bit of an oddity we want to be careful about how those internals are currently being relied on while making changes. That will be easier to do without having to also consider compile-time contexts. r? `@EddyB`
-
由 Ashley Mannix 提交于
-
由 bors 提交于
Rollup of 9 pull requests Successful merges: - #76898 (Record `tcx.def_span` instead of `item.span` in crate metadata) - #76939 (emit errors during AbstractConst building) - #76965 (Add cfg(target_has_atomic_equal_alignment) and use it for Atomic::from_mut.) - #76993 (Changing the alloc() to accept &self instead of &mut self) - #76994 (fix small typo in docs and comments) - #77017 (Add missing examples on Vec iter types) - #77042 (Improve documentation for ToSocketAddrs) - #77047 (Miri: more informative deallocation error messages) - #77055 (Add #[track_caller] to more panicking Cell functions) Failed merges: r? `@ghost`
-
由 bors 提交于
MIR pass to remove unneeded drops on types not needing drop This is heavily dependent on MIR inlining running to actually see the drop statement. Do we want to special case replacing a call to std::mem::drop with a goto aswell?
-
由 Simon Vandel Sillesen 提交于
-
- 23 9月, 2020 23 次提交
-
-
由 bors 提交于
Revert "Function to convert OpenOptions to c_int" Reverts rust-lang/rust#76110. This broke Rust's stability guarantees. Closes https://github.com/rust-lang/rust/issues/77089. r? `@joshtriplett`
-
由 Dylan DPC 提交于
Add #[track_caller] to more panicking Cell functions Continuation of #74526 Adds the #[track_caller] attribute to almost all panicking Cell functions. The ones that borrow two Cells in their function body are spared, because the panic location helps pinpoint which of the two borrows failed. You'd need to have full debuginfo and backtraces enabled together with column info in order to be able to discern the cases. Column info in debuginfo is only available on non-Windows platforms.
-
由 Dylan DPC 提交于
Miri: more informative deallocation error messages Make sure we show the affected AllocId. r? @oli-obk
-
由 Dylan DPC 提交于
Improve documentation for ToSocketAddrs I little clarification
-
由 Dylan DPC 提交于
Add missing examples on Vec iter types r? @Dylan-DPC
-
由 Dylan DPC 提交于
fix small typo in docs and comments Fixed `the the` to `the`, as far as I found.
-
由 Dylan DPC 提交于
Changing the alloc() to accept &self instead of &mut self Fixes: [#55](https://github.com/rust-lang/wg-allocators/issues/55) This is the first cut. It only makes the change for `alloc` method.
-
由 Dylan DPC 提交于
Add cfg(target_has_atomic_equal_alignment) and use it for Atomic::from_mut. Fixes some platform-specific problems with #74532 by using the actual alignment of the types instead of hardcoding a few `target_arch`s. r? @RalfJung
-
由 Dylan DPC 提交于
emit errors during AbstractConst building There changes are currently still untested, so I don't expect this to pass CI
😆 It seems to me like this is the direction we want to go in, though we didn't have too much of a discussion about this. r? @oli-obk -
由 Dylan DPC 提交于
Record `tcx.def_span` instead of `item.span` in crate metadata This was missed in PR #75465. As a result, a few places have been using the full body span of functions, instead of just the header span.
-
由 bors 提交于
Don't download/sync llvm-project submodule if download-ci-llvm is set llvm-project takes > 1GB storage space and a long time to download. It's better to not download it unless needed.
-
由 bors 提交于
SimplifyComparisonIntegral: fix miscompilation Fixes #76432 Only insert StorageDeads if we actually removed one. Fixes an issue where we added StorageDead to a place with no StorageLive r? `@oli-obk`
-
由 Andreas Jonson 提交于
remove the need for T to be copy from MiniSet as was done for MiniMap
-
由 bors 提交于
Remove `qualify_min_const_fn` ~~Blocked on #76807 (the first six commits).~~ With this PR, all checks in `qualify_min_const_fn` are replicated in `check_consts`, and the former is no longer invoked. My goal was to have as few changes to test output as possible, since making sweeping changes to the code *while* doing big batches of diagnostics updates turned out to be a headache. To this end, there's a few `HACK`s in `check_consts` to achieve parity with `qualify_min_const_fn`. The new system that replaces `is_min_const_fn` is referred to as "const-stability" My end goal for the const-stability rules is this: * Const-stability is only applicable to functions defined in `staged_api` crates. * All functions not marked `rustc_const_unstable` are considered "const-stable". - NB. This is currently not implemented. `#[unstable]` functions are also const-unstable. This causes problems when searching for feature gates. - All "const-unstable" functions have an associated feature gate * const-stable functions can only call other const-stable functions - `allow_internal_unstable` can be used to circumvent this. * All const-stable functions are subject to some additional checks (the ones that were unique to `qualify_min_const_fn`) The plan is to remove each `HACK` individually in subsequent PRs. That way, changes to error message output can be reviewed in isolation.
-
由 blitzerr 提交于
-
由 blitzerr 提交于
-
由 Joshua Nelson 提交于
-
由 bors 提交于
Rebase LLVM onto 11.0.0-rc3 r? `@nikic`
-
由 Ashley Mannix 提交于
This reverts commit e3856616.
-
由 bors 提交于
cache types during normalization partially fixes #75992 reduces the following test from 14 to 3 seconds locally. cc `@Mark-Simulacrum` would it make sense to add that test to `perf`? ```rust #![recursion_limit="2048"] #![type_length_limit="112457564"] pub async fn h0(v: &String, x: &u64) { println!("{} {}", v, x) } pub async fn h1(v: &String, x: &u64) { h0(v, x).await } pub async fn h2(v: &String, x: &u64) { h1(v, x).await } pub async fn h3(v: &String, x: &u64) { h2(v, x).await } pub async fn h4(v: &String, x: &u64) { h3(v, x).await } pub async fn h5(v: &String, x: &u64) { h4(v, x).await } pub async fn h6(v: &String, x: &u64) { h5(v, x).await } pub async fn h7(v: &String, x: &u64) { h6(v, x).await } pub async fn h8(v: &String, x: &u64) { h7(v, x).await } pub async fn h9(v: &String, x: &u64) { h8(v, x).await } pub async fn h10(v: &String, x: &u64) { h9(v, x).await } pub async fn h11(v: &String, x: &u64) { h10(v, x).await } pub async fn h12(v: &String, x: &u64) { h11(v, x).await } pub async fn h13(v: &String, x: &u64) { h12(v, x).await } pub async fn h14(v: &String, x: &u64) { h13(v, x).await } pub async fn h15(v: &String, x: &u64) { h14(v, x).await } pub async fn h16(v: &String, x: &u64) { h15(v, x).await } pub async fn h17(v: &String, x: &u64) { h16(v, x).await } pub async fn h18(v: &String, x: &u64) { h17(v, x).await } pub async fn h19(v: &String, x: &u64) { h18(v, x).await } macro_rules! async_recursive { (29, $inner:expr) => { async { async_recursive!(28, $inner) }.await }; (28, $inner:expr) => { async { async_recursive!(27, $inner) }.await }; (27, $inner:expr) => { async { async_recursive!(26, $inner) }.await }; (26, $inner:expr) => { async { async_recursive!(25, $inner) }.await }; (25, $inner:expr) => { async { async_recursive!(24, $inner) }.await }; (24, $inner:expr) => { async { async_recursive!(23, $inner) }.await }; (23, $inner:expr) => { async { async_recursive!(22, $inner) }.await }; (22, $inner:expr) => { async { async_recursive!(21, $inner) }.await }; (21, $inner:expr) => { async { async_recursive!(20, $inner) }.await }; (20, $inner:expr) => { async { async_recursive!(19, $inner) }.await }; (19, $inner:expr) => { async { async_recursive!(18, $inner) }.await }; (18, $inner:expr) => { async { async_recursive!(17, $inner) }.await }; (17, $inner:expr) => { async { async_recursive!(16, $inner) }.await }; (16, $inner:expr) => { async { async_recursive!(15, $inner) }.await }; (15, $inner:expr) => { async { async_recursive!(14, $inner) }.await }; (14, $inner:expr) => { async { async_recursive!(13, $inner) }.await }; (13, $inner:expr) => { async { async_recursive!(12, $inner) }.await }; (12, $inner:expr) => { async { async_recursive!(11, $inner) }.await }; (11, $inner:expr) => { async { async_recursive!(10, $inner) }.await }; (10, $inner:expr) => { async { async_recursive!(9, $inner) }.await }; (9, $inner:expr) => { async { async_recursive!(8, $inner) }.await }; (8, $inner:expr) => { async { async_recursive!(7, $inner) }.await }; (7, $inner:expr) => { async { async_recursive!(6, $inner) }.await }; (6, $inner:expr) => { async { async_recursive!(5, $inner) }.await }; (5, $inner:expr) => { async { async_recursive!(4, $inner) }.await }; (4, $inner:expr) => { async { async_recursive!(3, $inner) }.await }; (3, $inner:expr) => { async { async_recursive!(2, $inner) }.await }; (2, $inner:expr) => { async { async_recursive!(1, $inner) }.await }; (1, $inner:expr) => { async { async_recursive!(0, $inner) }.await }; (0, $inner:expr) => { async { h19(&String::from("owo"), &0).await; $inner }.await }; } async fn f() { async_recursive!(14, println!("hello")); } fn main() { let _ = f(); } ``` r? `@EddyB` requires a perf run.
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
-
由 Simon Vandel Sillesen 提交于
-