- 07 7月, 2020 8 次提交
-
-
由 Manish Goregaokar 提交于
Move A|Rc::as_ptr from feature(weak_into_raw) to feature(rc_as_ptr) These were stabilized alongside the Weak versions, but having `feature = "weak_.."` on a fn definition for the non-weak pointers is potentially very misleading, especially in a review context where the impl header may not be immediately visible. r? @RalfJung @bors rollup=always
-
由 Manish Goregaokar 提交于
mir: mark mir construction temporaries as internal Fixes #73914. This PR marks temporaries from MIR construction as internal such that they are skipped in `sanitize_witness` (where each MIR local is checked to have been contained within the generator interior computed during typeck). This resolves an ICE whereby the construction of checked addition introduced a `(u64, bool)` temporary which was not in the HIR and thus not in the generator interior. r? @matthewjasper
-
由 Manish Goregaokar 提交于
libstd/net/tcp.rs: #![deny(unsafe_op_in_unsafe_fn)] Enclose unsafe operations in unsafe blocks for net/tcp.rs. Fixes part of #73904.
-
由 Manish Goregaokar 提交于
Audit hidden/short code suggestions Should fix #73641. Audit uses of `span_suggestion_short` and `tool_only_span_suggestion` (`span_suggestion_hidden` is already tested with `run-rustfix`). Leave some FIXMEs for futher improvements/fixes. r? @estebank
-
由 Manish Goregaokar 提交于
typeck: adding type information to projection This commit modifies the Place as follow: * remove 'ty' from ProjectionKind * add type information into to Projection * replace 'ty' in Place with 'base_ty' * introduce 'ty()' in `Place` to return the final type of the `Place` * introduce `ty_before_projection()` in `Place` to return the type of a `Place` before i'th projection is applied Closes https://github.com/rust-lang/project-rfc-2229/issues/5
-
由 Manish Goregaokar 提交于
Edit librustc_lexer top-level docs Minor edit, and adds link to librustc_parse::lexer.
-
由 Manish Goregaokar 提交于
[rustdoc] Page hash handling Fixes https://github.com/rust-lang/rust/issues/70476 A good example to see the change is to use this URL: https://doc.rust-lang.org/nightly/std/string/struct.String.html#from_iter.v-3 After the change, it actually goes to the target element (and change the page hash to something more clear for the users). r? @kinnison cc @ollie27
-
由 pierwill 提交于
Add link to librustc_parse::lexer
-
- 06 7月, 2020 15 次提交
-
-
由 bors 提交于
Rollup of 12 pull requests Successful merges: - #72688 (added .collect() into String from Box<str>) - #73787 (Add unstable docs for rustc_attrs) - #73834 (Some refactoring around intrinsic type checking) - #73871 (Fix try_print_visible_def_path for Rust 2018) - #73937 (Explain exhaustive matching on {usize,isize} maximum values) - #73973 (Use `Span`s to identify unreachable subpatterns in or-patterns) - #74000 (add `lazy_normalization_consts` feature gate) - #74025 (Remove unnecessary release from Arc::try_unwrap) - #74027 (Convert more `DefId`s to `LocalDefId`s) - #74055 (Fix spacing in Iterator fold doc) - #74057 (expected_found `&T` -> `T`) - #74064 (variant_count: avoid incorrect dummy implementation) Failed merges: r? @ghost
-
由 Manish Goregaokar 提交于
variant_count: avoid incorrect dummy implementation This also avoids a stage 0 doctest failure.
-
由 Manish Goregaokar 提交于
expected_found `&T` -> `T`
-
由 Manish Goregaokar 提交于
Fix spacing in Iterator fold doc
-
由 Manish Goregaokar 提交于
Convert more `DefId`s to `LocalDefId`s
-
由 Manish Goregaokar 提交于
Remove unnecessary release from Arc::try_unwrap The thread that recovers the unique access to Arc inner value (e.g., drop when ref-count strong reaches zero, successful try_unwrap), ensures that other operations on Arc inner value happened before by synchronizing with release operations performed when decrementing the reference counter. When try_unwrap succeeds, the current thread recovers the unique access to Arc inner value, so release is unnecessary. r? @Amanieu
-
由 Manish Goregaokar 提交于
add `lazy_normalization_consts` feature gate In #71973 I underestimated the amount of code which is influenced by lazy normalization of consts and decided against having a separate feature flag for this. Looking a bit more into this, the following issues are already working with lazy norm in its current state #47814 #57739 #73980 I therefore think it is worth it to enable lazy norm separately. Note that `#![feature(const_generics)]` still automatically activates this feature, so using `#![feature(const_generics, lazy_normalization_consts)]` is redundant. r? @varkor @nikomatsakis
-
由 Manish Goregaokar 提交于
Use `Span`s to identify unreachable subpatterns in or-patterns Fixes #71977
-
由 Manish Goregaokar 提交于
Explain exhaustive matching on {usize,isize} maximum values The wording is taken from https://github.com/rust-lang/rfcs/blob/master/text/2591-exhaustive-integer-pattern-matching.md#reference-level-explanation. Fixes #73919 r? @varkor
-
由 Manish Goregaokar 提交于
Fix try_print_visible_def_path for Rust 2018 The recursive check of `try_print_visible_def_path` did not properly handle the Rust 2018 case of crate-paths without 'extern crate'. Instead, it returned a "not found" via (false, self). This fixes #56175.
-
由 Manish Goregaokar 提交于
Some refactoring around intrinsic type checking So... This PR went a bit overboard. I wanted to make the `rustc_peek` intrinsic safe (cc @ecstatic-morse ), and remembered a long-standing itch of mine. So I made that huge `&str` match for the intrinsic name a match on `Symbol`s (so basically `u32`s). This is unlikely to have a positive perf effect, even if it likely has better codegen (intrinsics are used rarely, mostly once in their wrapper), so it's mostly a consistency thing since other places actually match on the symbol name of the intrinsics.
-
由 Manish Goregaokar 提交于
Add unstable docs for rustc_attrs r? @RalfJung
-
由 Manish Goregaokar 提交于
added .collect() into String from Box<str> I have not created an rfc, because i felt like this is a very minor change. i have just set a random feature name and rust version as stability attribute, i expect to have to change that, i just don't know what the policy on that is. all guides i could find focused on contributing to the compiler, not contributing to the standard library. drawbacks: more code in the standard library, could be replaced with specialization: base-implementation for AsRef\<str> and specialization for String and Cow. i can write that code if ppl want it. advantages: using "real strings" i.e. Box\<str> is as ergonomic as string slices (&str) and string buffers (String) with iterators.
-
由 bors 提交于
Handle inactive enum variants in `MaybeUninitializedPlaces` Resolves the first part of #69715. This is the equivalent of #68528 but for `MaybeUninitializedPlaces`. Because we now notify drop elaboration that inactive enum variants might be uninitialized, some drops get marked as ["open" that were previously "static"](https://github.com/rust-lang/rust/blob/e0e5d82e1677c82d209b214bbfc2cc5705c2336a/src/librustc_mir/transform/elaborate_drops.rs#L191). Unlike in #69715, this isn't strictly better: An "open" drop expands to more MIR than a simple call to the drop shim. However, because drop elaboration considers each field of an "open" drop separately, it can sometimes eliminate unnecessary drops of moved-from or unit-like enum variants. This is the case for `Option::unwrap`, which is reflected in the `mir-opt` test. cc @EddyB r? @oli-obk
-
由 Ralf Jung 提交于
-
- 05 7月, 2020 7 次提交
-
-
由 Bastian Kauschke 提交于
-
由 Ivan Tham 提交于
-
由 Nadrieril 提交于
-
由 Yuki Okushi 提交于
-
由 Yuki Okushi 提交于
-
由 Oliver Scherer 提交于
-
由 Oliver Scherer 提交于
-
- 04 7月, 2020 10 次提交
-
-
由 Bastian Kauschke 提交于
Co-authored-by: Nvarkor <github@varkor.com>
-
由 Bastian Kauschke 提交于
-
由 Bastian Kauschke 提交于
-
由 Tomasz Miąsko 提交于
The thread that recovers the unique access to Arc inner value (e.g., drop when ref-count strong reaches zero, successful try_unwrap), ensures that other operations on Arc inner value happened before by synchronizing with release operations performed when decrementing the reference counter. When try_unwrap succeeds, the current thread recovers the unique access to Arc inner value, so release is unnecessary.
-
由 Bastian Kauschke 提交于
-
由 bors 提交于
ship rust analyzer This successfully builds rust-analyzer as a part of rust repo. I haven't yet added required changes to dist.rs -- seems like I just have to copy-paste quite a bit of code I don't really understand :-)
-
由 bors 提交于
Rollup of 12 pull requests Successful merges: - #73140 (Fallback to xml.etree.ElementTree) - #73670 (Add `format_args_capture` feature) - #73693 (Use exhaustive match in const_prop.rs) - #73845 (Use &raw in A|Rc::as_ptr) - #73861 (Create E0768) - #73881 (Standardize bibliographic citations in rustc API docs) - #73925 (Improve comments from #72617, as suggested by RalfJung) - #73949 ([mir-opt] Fix mis-optimization and other issues with the SimplifyArmIdentity pass) - #73984 (Edit docs for rustc_data_structures::graph::scc) - #73985 (Fix "getting started" link) - #73997 (fix typo) - #73999 (Bump mingw-check CI image from Ubuntu 16.04 to 18.04.) Failed merges: - #74000 (add `lazy_normalization_consts` feature gate) r? @ghost
-
由 Manish Goregaokar 提交于
Bump mingw-check CI image from Ubuntu 16.04 to 18.04. I chose 18.04 because we use it for other builders, and it's enough to get a version of MinGW that can build `libssh2-sys`. This is a prereq for #73902, where `libssh2-sys` shows up as an indirect dependency of `x.py check src/tools/semverver` (through `src/tools/cargo`, which we don't currently `x.py check` because it's not in-tree). See also https://github.com/rust-lang/rust/pull/73902#issuecomment-652414502. r? @Mark-Simulacrum cc @mati865
-
由 Manish Goregaokar 提交于
fix typo r? @Dylan-DPC
-
由 Manish Goregaokar 提交于
Fix "getting started" link The previous link is 404.
-