profile
viewpoint

ecstatic-morse/enum-utils 6

A set of useful proc macros for enums

ecstatic-morse/ksuid 5

A small utility for dealing with Segment.io KSUIDs

ecstatic-morse/atdf 1

A parser for AVR's system description files (.atdf).

ecstatic-morse/fixed-bitset 1

A bitset whose size is fixed at compile-time

ecstatic-morse/anglistic-sched 0

A scheduler for matching students to presentation time slots by preference

ecstatic-morse/blog.rust-lang.org 0

The Rust Programming Language Blog

ecstatic-morse/cargo 0

The Rust package manager

ecstatic-morse/competitive-coding-demo 0

An example of a solution to a coding problem

ecstatic-morse/compiler-team 0

A home for compiler team planning documents, meeting minutes, and other such things.

ecstatic-morse/const-eval 0

home for proposals in and around compile-time function evaluation

pull request commentrust-lang/rust

forbid `#[track_caller]` on main

@bors r- The stdarch bump got added back in the last commit. git add -p is your friend :smile:.

lcnr

comment created time in 4 hours

pull request commentrust-lang/rust

forbid `#[track_caller]` on main

r=me with the error message tweaked.

lcnr

comment created time in 5 hours

Pull request review commentrust-lang/rust

forbid `#[track_caller]` on main

 fn check_start_fn_ty(tcx: TyCtxt<'_>, start_def_id: LocalDefId) {                         .emit();                         error = true;                     }++                    for attr in it.attrs {+                        if attr.check_name(sym::track_caller) {+                            tcx.sess+                                .struct_span_err(+                                    attr.span,+                                    "start is not allowed to be `#[track_caller]`",
                                    "`start` is not allowed to be `#[track_caller]`",

Same below. Also, maybe this should just say "program entry point is not allowed..."? Up to you.

lcnr

comment created time in 5 hours

pull request commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

@bors rollup

@oli-obk r=me when you're happy

oli-obk

comment created time in 4 days

Pull request review commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

 impl<'a, 'tcx> CfgSimplifier<'a, 'tcx> {             } if statements.is_empty() => terminator.take(),             // if `terminator` is None, this means we are in a loop. In that             // case, let all the loop collapse to its entry.-            _ => return,-        };--        let target = match terminator {-            Some(Terminator { kind: TerminatorKind::Goto { ref mut target }, .. }) => {-                self.collapse_goto_chain(target, changed);-                *target-            }-            _ => unreachable!(),-        };-        self.basic_blocks[*start].terminator = terminator;--        debug!("collapsing goto chain from {:?} to {:?}", *start, target);--        *changed |= *start != target;+            _ => None,+        }+    } -        if self.pred_count[*start] == 1 {-            // This is the last reference to *start, so the pred-count to-            // to target is moved into the current block.-            self.pred_count[*start] = 0;-        } else {-            self.pred_count[target] += 1;-            self.pred_count[*start] -= 1;+    // Collapse a goto chain starting from `start`+    fn collapse_goto_chain(&mut self, start: &mut BasicBlock, changed: &mut bool) {+        let mut terminators: SmallVec<[_; 1]> = Default::default();

Sounds good. It shouldn't matter much either way, maybe leave a comment?

oli-obk

comment created time in 4 days

Pull request review commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

 impl<'a, 'tcx> CfgSimplifier<'a, 'tcx> {             } if statements.is_empty() => terminator.take(),             // if `terminator` is None, this means we are in a loop. In that             // case, let all the loop collapse to its entry.-            _ => return,-        };--        let target = match terminator {-            Some(Terminator { kind: TerminatorKind::Goto { ref mut target }, .. }) => {-                self.collapse_goto_chain(target, changed);-                *target-            }-            _ => unreachable!(),-        };-        self.basic_blocks[*start].terminator = terminator;--        debug!("collapsing goto chain from {:?} to {:?}", *start, target);--        *changed |= *start != target;+            _ => None,+        }+    } -        if self.pred_count[*start] == 1 {-            // This is the last reference to *start, so the pred-count to-            // to target is moved into the current block.-            self.pred_count[*start] = 0;-        } else {-            self.pred_count[target] += 1;-            self.pred_count[*start] -= 1;+    // Collapse a goto chain starting from `start`+    fn collapse_goto_chain(&mut self, start: &mut BasicBlock, changed: &mut bool) {+        let mut terminators: SmallVec<[_; 1]> = Default::default();+        let mut current = *start;+        while let Some(terminator) = self.extract_terminator(current) {+            let target = match terminator {+                Terminator { kind: TerminatorKind::Goto { target }, .. } => target,+                _ => unreachable!(),+            };+            terminators.push((current, terminator));+            current = target;         }+        let last = current;+        *start = last;+        while let Some((current, mut terminator)) = terminators.pop() {+            let target = match terminator {+                Terminator { kind: TerminatorKind::Goto { ref mut target }, .. } => target,+                _ => unreachable!(),+            };+            *target = last;+            debug!("collapsing goto chain from {:?} to {:?}", current, target); -        *start = target;+            if self.pred_count[current] == 1 {+                // This is the last reference to current, so the pred-count to+                // to target is moved into the current block.+                self.pred_count[current] = 0;+            } else {+                self.pred_count[*target] += 1;+                self.pred_count[current] -= 1;+            }+            *changed |= current != *target;

If you don't wanna lump it into this PR, that's fine too. It just doesn't quite make sense to me.

oli-obk

comment created time in 4 days

Pull request review commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

 impl<'a, 'tcx> CfgSimplifier<'a, 'tcx> {             } if statements.is_empty() => terminator.take(),             // if `terminator` is None, this means we are in a loop. In that             // case, let all the loop collapse to its entry.-            _ => return,-        };--        let target = match terminator {-            Some(Terminator { kind: TerminatorKind::Goto { ref mut target }, .. }) => {-                self.collapse_goto_chain(target, changed);-                *target-            }-            _ => unreachable!(),-        };-        self.basic_blocks[*start].terminator = terminator;--        debug!("collapsing goto chain from {:?} to {:?}", *start, target);--        *changed |= *start != target;+            _ => None,+        }+    } -        if self.pred_count[*start] == 1 {-            // This is the last reference to *start, so the pred-count to-            // to target is moved into the current block.-            self.pred_count[*start] = 0;-        } else {-            self.pred_count[target] += 1;-            self.pred_count[*start] -= 1;+    // Collapse a goto chain starting from `start`+    fn collapse_goto_chain(&mut self, start: &mut BasicBlock, changed: &mut bool) {+        let mut terminators: SmallVec<[_; 1]> = Default::default();+        let mut current = *start;+        while let Some(terminator) = self.extract_terminator(current) {+            let target = match terminator {+                Terminator { kind: TerminatorKind::Goto { target }, .. } => target,+                _ => unreachable!(),+            };+            terminators.push((current, terminator));+            current = target;         }+        let last = current;+        *start = last;+        while let Some((current, mut terminator)) = terminators.pop() {+            let target = match terminator {+                Terminator { kind: TerminatorKind::Goto { ref mut target }, .. } => target,+                _ => unreachable!(),+            };+            *target = last;+            debug!("collapsing goto chain from {:?} to {:?}", current, target); -        *start = target;+            if self.pred_count[current] == 1 {+                // This is the last reference to current, so the pred-count to+                // to target is moved into the current block.+                self.pred_count[current] = 0;+            } else {+                self.pred_count[*target] += 1;+                self.pred_count[current] -= 1;+            }+            *changed |= current != *target;

Preexisting I know, but why do we only mark the MIR as changed if current != target? If current == target then we are inserting a self-loop, but it's possible for this to represent a change in the MIR if we had a cycle involving several Gotos.

oli-obk

comment created time in 4 days

Pull request review commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

 impl<'a, 'tcx> CfgSimplifier<'a, 'tcx> {             } if statements.is_empty() => terminator.take(),             // if `terminator` is None, this means we are in a loop. In that             // case, let all the loop collapse to its entry.-            _ => return,-        };--        let target = match terminator {-            Some(Terminator { kind: TerminatorKind::Goto { ref mut target }, .. }) => {-                self.collapse_goto_chain(target, changed);-                *target-            }-            _ => unreachable!(),-        };-        self.basic_blocks[*start].terminator = terminator;--        debug!("collapsing goto chain from {:?} to {:?}", *start, target);--        *changed |= *start != target;+            _ => None,+        }+    } -        if self.pred_count[*start] == 1 {-            // This is the last reference to *start, so the pred-count to-            // to target is moved into the current block.-            self.pred_count[*start] = 0;-        } else {-            self.pred_count[target] += 1;-            self.pred_count[*start] -= 1;+    // Collapse a goto chain starting from `start`+    fn collapse_goto_chain(&mut self, start: &mut BasicBlock, changed: &mut bool) {+        let mut terminators: SmallVec<[_; 1]> = Default::default();

Why the SmallVec here? In the common case, start will not refer to a Goto with no statements, so terminators will be empty.

oli-obk

comment created time in 4 days

Pull request review commentrust-lang/rust

Replace a recursive algorithm with an iterative one and a stack.

 impl<'a, 'tcx> CfgSimplifier<'a, 'tcx> {         }     } -    // Collapse a goto chain starting from `start`-    fn collapse_goto_chain(&mut self, start: &mut BasicBlock, changed: &mut bool) {-        let mut terminator = match self.basic_blocks[*start] {+    fn extract_terminator(&mut self, bb: BasicBlock) -> Option<Terminator<'tcx>> {

Can we use a more descriptive name for this? take_terminator_if_simple_goto or so?

oli-obk

comment created time in 4 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 96c84ac3cbc4f2c81580893dacf263d00306649c

Test `Option::unwrap` in a const context

view details

push time in 5 days

pull request commentrust-lang/rust

Make `Option::unwrap` unstably const

The error annotations in the test are a bit weird, but it's more of a problem for compiletest than for users.

ecstatic-morse

comment created time in 5 days

PR opened rust-lang/rust

Make `Option::unwrap` unstably const

This is lumped into the const_option feature gate (#67441), which enables a potpourri of Option methods.

cc @rust-lang/wg-const-eval

r? @oli-obk

+37 -1

0 comment

4 changed files

pr created time in 5 days

create barnchecstatic-morse/rust

branch : const-option-unwrap

created branch time in 5 days

issue commentrust-lang/rust

Error about drop in `const fn` without any dropping happening

This particular example is fixed by #![feature(const_precise_live_drops)] (#73255), which moves live drop checking for constants after drop elaboration. I think we can close this?

oli-obk

comment created time in 5 days

pull request commentrust-lang/rust

Improve diagnostics when constant pattern is too generic

Thanks!

@bors r+ rollup

nbdd0121

comment created time in 5 days

delete branch ecstatic-morse/rust

delete branch : const-size-align-of-val

delete time in 5 days

pull request commentrust-lang/rust

Make `mem::size_of_val` and `mem::align_of_val` unstably const

Please also open a PR against miri, removing the intrinsics there

Resolved in rust-lang/miri#1912 (thanks Ralf!)

ecstatic-morse

comment created time in 5 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 88fd4943a65fe7b18c0468255c54f9dee591dd1b

Test `{align,size}_of_val` in a const context

view details

push time in 6 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 34eaffb3546113b3935390e8f31226435a0178fd

Test `{align,size}_of_val` in a const context

view details

push time in 6 days

PR opened rust-lang/rust

Make `mem::size_of_val` and `mem::align_of_val` unstably const

Implements #46571 but does not stabilize it. I wanted this while working on something today.

The only reason not to immediately stabilize are concerns around custom DSTs. That proposal has made zero progress in the last two years and const eval is rich enough to support pretty much any user-defined len function as long as nightly features are allowed (raw_ptr_deref).

r? @oli-obk

cc @rust-lang/wg-const-eval

+97 -3

0 comment

7 changed files

pr created time in 6 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 9caf0b52229ff935a17ff42f91e843b3d3d264e8

Make `{align,size}_of_val` `const`

view details

Dylan MacKenzie

commit sha 7f4a5c066f86d70f176a86446fca74fe7187755b

Test `{align,size}_of_val` in a const context

view details

push time in 6 days

create barnchecstatic-morse/rust

branch : const-size-align-of-val

created branch time in 6 days

pull request commentrust-lang/rust

Add `#[cfg(panic = '...')]`

I'd like to see a test verifying that -C panic=abort actually causes the cfg(panic = "abort") code to run and vice versa. Also, I think this needs sign off from @rust-lang/lang, but an RFC is probably overkill.

davidhewitt

comment created time in 6 days

pull request commentrust-lang/rust

Make closures and generators a must use types

@bors rollup

tmiasko

comment created time in 6 days

pull request commentrust-lang/rust

Make closures and generators a must use types

LGTM. Thanks!

@bors r+

tmiasko

comment created time in 6 days

pull request commentrust-lang/rust

Rewrite the `Visitor` for `non_ssa_locals`

I made the requested changes @eddyb, can you take another look?

ecstatic-morse

comment created time in 10 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha d9df24c5b2809acc23a0c4634fa1f2d967da6aae

Use loop instead of visitor to check for invalid projections

view details

Dylan MacKenzie

commit sha 8d8e59e6ee1c71d710a04e02aab4b9300c4dc23c

`first_assignment` no longer needs a getter

view details

Dylan MacKenzie

commit sha 647d788dc7061e13109d6323076fb4379e7cb96d

Ignore `VarDebugInfo` when forcing locals on the stack

view details

Dylan MacKenzie

commit sha 86bf63aa07d635a926b898a28ae53c6762b0a46f

Remove outdated comment

view details

push time in 13 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 3c904a78d049f8e62d330ca2eacd65b588c8a96f

Use loop instead of visitor to check for invalid projections

view details

Dylan MacKenzie

commit sha 1b018b61714724d2b68d23b08ab8e3d3099e9e38

`first_assignment` no longer needs a getter

view details

Dylan MacKenzie

commit sha f3219f4cb84364d906f2bcfdc0f5960898f0855b

Ignore `VarDebugInfo` when forcing locals on the stack

view details

Dylan MacKenzie

commit sha 8f82918bdf11862d6aa8ce32fb457335f558cceb

Remove outdated comment

view details

push time in 13 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha edb0939aec60a040a49b778344a2bbeb85b538f1

Use loop instead of visitor to check for invalid projections

view details

Dylan MacKenzie

commit sha 62e1ecadee04f43930db26ff844c4679a1764b41

`first_assignment` no longer needs a getter

view details

Dylan MacKenzie

commit sha bd7b64a30b65695e8d96b0fa1794f788943a774d

Ignore `VarDebugInfo` when forcing locals on the stack

view details

Dylan MacKenzie

commit sha 8a754fa489d750c5dae06ec38e32df727df43c3d

Remove outdated comment

view details

push time in 13 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 844fcc8034301ae992b5a837099bbaff5b5f7cc0

Use loop instead of visitor to check for invalid projections

view details

Dylan MacKenzie

commit sha 00225de6ce27e00ff88f01e3a3ae86398b942f2b

`first_assignment` no longer needs a getter

view details

Dylan MacKenzie

commit sha 7d12dacae0a99803055823dc003ed984d571468c

Ignore `VarDebugInfo` when forcing locals on the stack

view details

Dylan MacKenzie

commit sha ffb4f0a691ed8c6d48594d0043a3db9088521a70

Remove outdated comment

view details

push time in 13 days

issue commentrust-lang/rust

error: could not compile `gkrust` since Rust 1.43 on SPARC Solaris

Plus I believe ASan is not available for SPARC.

Oof. This is gonna be a tough one to figure out.

This kind of issues are often caught by LLVM assertions.

CI builds and tests rustc with LLVM assertions enabled for all tier 1 platforms. I'd be surprised if we were violating an assertion late enough in the compilation pipeline that it only triggered on SPARC, but it doesn't hurt to check.

psumbera

comment created time in 13 days

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 73c954aec58ad8d7b73735fe91f3668fa4217f5e

Revert "Ignore `VarDebugInfo` when forcing locals on the stack" This reverts commit f54be2ba0fb6d430abace1b049ac72471386c2b2.

view details

push time in 13 days

PR closed rust-lang/rust

Bail out early from `truncate` if the new length is equal to the old S-waiting-on-review

truncate should do nothing for collections if the new length is equal to the current length, but this is not explicitly stated in the code. Instead, control flow continues in this case until an empty slice is passed to drop_in_place. While this is equivalent and likely optimizes to the same code, it is not as clear and edit: results in slightly worse codegen for vectors containing types with Drop glue.

+23 -9

5 comments

3 changed files

ecstatic-morse

pr closed time in 13 days

pull request commentrust-lang/rust

Advertise correct stable version for const control flow

@bors r=jonas-schievink

Sorry. This fell off the radar.

ecstatic-morse

comment created time in 13 days

push eventecstatic-morse/rust

Yoshua Wuyts

commit sha a31f103fd27bde3f83b9dd54af8e41d64e5001f4

Add core::future::{poll_fn, PollFn}

view details

Caio

commit sha 187aea7c34adf06b0db39f688d60d3fdac8e7e3e

Impl Default for ranges

view details

Mohsen Zohrevandi

commit sha c4b02659c16d2ad0ac36d2c8602edd002e559f7a

Enable some timeouts in SGX platform This would partially resolve https://github.com/fortanix/rust-sgx/issues/31

view details

Mohsen Zohrevandi

commit sha d7dc64bdfea4fbf8974774800ab51e04eaa4f082

Handle spurious wakeups in wait_timeout_sgx

view details

Mohsen Zohrevandi

commit sha c5d1fcd2309b6903fed82aba6e0fdc2fa85bc874

Allow more ui tests for SGX

view details

Alexis Bourget

commit sha 049f6eaa792fbbf2b727fc278ddd23d1e11d57bd

Fixing broken link for the Eq trait

view details

Teddy_Wang

commit sha 40ee620e51c86c72e3c2b65df71f5f0a4a79797f

Added a lint for .map(|x| x)

view details

Mohsen Zohrevandi

commit sha 3442d23c1a12f1f01a0e07b6bec72b58998f49ef

Improve wait_timeout_sgx, simplify usercalls::wait

view details

CAD97

commit sha 7779a11448927e208ed6eb9bb609dd23595f77ce

Use step_unchecked more liberally

view details

Alexis Bourget

commit sha 6e8251742071d56545b6ce160ed71bb60597ee01

Documenting the separate behaviors of edition 2015 and 2018

view details

Alexis Bourget

commit sha 59701360dc0c76bfa45204d307ac5055f8bff538

Fix some small mistakes

view details

flip1995

commit sha 80bcbf521c7ff95e38a7567432b5519cc18e5b2a

Merge commit 'c2c07fa9d095931eb5684a42942a7b573a0c5238' into clippyup

view details

Teddy_Wang

commit sha fb4f9a0ad7a4656beb01c85b02b3e6ef15d914ec

Fix pattern match of ExprKind::MethodCall

view details

bors

commit sha 583d64493484f72425ecac55eaf5eddbba10b132

Auto merge of #5694 - wangtheo:issue-5626, r=matthiaskrgr #5626: lint iterator.map(|x| x) changelog: adds a new lint for iterator.map(|x| x) (see https://github.com/rust-lang/rust-clippy/issues/5626) The code also lints for result.map(|x| x) and option.map(|x| x). Also, I'm not sure if I'm checking for type adjustments correctly and I can't think of an example where .map(|x| x) would apply type adjustments.

view details

Ayaz Hafiz

commit sha 7c1b3aa0ddb81954a804455ca45fcf09fdb17dd8

Record span of `const` kw in GenericParamKind Context: this is needed to fix https://github.com/rust-lang/rustfmt/issues/4263, which currently records the span of a const generic param incorrectly because the location of the `const` kw is not known. I am not sure how to add tests for this; any guidance in how to do so would be appreciated :slightly_smiling_face:

view details

Eduardo Broto

commit sha 5987c7d4041ce5d72c8412d2ad73fe3b63308b51

cmp_owned: avoid FP when PartialEq is not implemented symmetrically

view details

Eduardo Broto

commit sha b498e1d71537a79e7aff5378da625aca8b4eef96

cmp_owned: reverse operands if necessary

view details

Tim Nielens

commit sha 6bf5434e19ce6d2a501589d1fcbc0d1748c531a6

copy_on_clone - add machine applicability

view details

bors

commit sha a14eab389f6e9f8bdaffbba184b20220041b036f

Auto merge of #5745 - montrivo:copy_on_clone, r=phansch clone_on_copy - add machine applicability Fix #4826. Change the applicability of the lint clone_on_copy. Split a test file and run rustfix on the clone_on_copy part. changelog: clone_on_copy - add machine applicability

view details

bors

commit sha 46d33043d5de0403a2a3dab9e7817041999bf9dd

Auto merge of #5701 - ebroto:4874_cmp_owned_fp, r=flip1995 cmp_owned: handle when PartialEq is not implemented symmetrically changelog: Handle asymmetrical implementations of PartialEq in [`cmp_owned`]. Fixes #4874

view details

push time in 13 days

issue commentrust-lang/rust

error: could not compile `gkrust` since Rust 1.43 on SPARC Solaris

This is concerning. To confirm, this occurs with recent nightlies as well?

The commit you bisected to (part of #69676) re-enabled the optimization around drop elaboration in #68528, which could have plausibly caused this kind of issue. There's nothing target-dependent about that PR, so while it's possible that #68528 triggered a SPARC-only LLVM bug, it's very possible that there's a latent miscompilation on other platforms as well that manifests as a segmentation fault due to some detail of SPARC. However, it's surprising that we didn't see any issues from users on Intel machines.

The innermost frame points to this implementation detail of Cstring::new. There's no match on a type that has a drop implementation along that code path, so presumably the root cause is elsewhere. My next step for debugging this would probably be ASan, although I haven't had to use it in anger on Rust code yet.

Nominating for @rust-lang/compiler discussion to put this on their radar, since it could affect tier 1 platforms as well.

psumbera

comment created time in 14 days

push eventecstatic-morse/rust

Chris Denton

commit sha 912963bd0856239828253af8d04e4f62e75cafd7

Remove legacy InnoSetup GUI installer On Windows the InnoSetup installer was superseded by the MSI installer. It's no longer needed.

view details

djugei

commit sha b4337ab8c387658b7012fa242e429f46c5f31141

added .collect() into String from Box<str> with fake feature/stability annotation

view details

Yoshua Wuyts

commit sha 8bc6b5b45c9f9710852e2b9c57eb3d44d08ad245

stabilize leading_trailing_ones

view details

Tomasz Miąsko

commit sha 291dce91b24d70382ebf1116fa836fd91960de84

Fallback to xml.etree.ElementTree The xml.etree.cElementTree has been deprecated since Python 3.3 and removed in Python 3.9 https://bugs.python.org/issue36543.

view details

Caleb Zulawski

commit sha 144206e6d8c1ab4ffdbaf6d7b0f5a4201c0f2da4

Don't implement Fn* traits for #[target_feature] functions

view details

Caleb Zulawski

commit sha c98b4c8fdde7812d7af5a060a1e22fd7e3775d3f

Add error note when trying fn as Fn trait

view details

pankajchaudhary5

commit sha 46bfc48272ba5312c439557e2901e1a4778e9487

Added proper explanation of ErrorCode-E0687

view details

mark

commit sha 3f6928f1f6eff367e6ddbfb63ebc5e568ffe0eb1

move contributing.md to rustc-dev-guide and point at getting started

view details

Matthias Krüger

commit sha 1d0378c454de72ddcfc08bcc105744923ef2d4d4

impl From<char> for String This allows us to write fn char_to_string() -> String { 'a'.into() } which was not possible before.

view details

Tomasz Miąsko

commit sha 5c20ef433b48fce78c07208710bcc8b53965eeb1

bootstrap: Configurable musl libdir Make it possible to customize the location of musl libdir using musl-libdir in config.toml, e.g., to use lib64 instead of lib.

view details

Matthias Krüger

commit sha 2cde4932c7e8bd6000378af41029299ccf6eea69

add test for char into string

view details

VillSnow

commit sha 4c8ce48a15c88715955e56c9c35959d9dffad5ec

Add partition_point

view details

VillSnow

commit sha c9b49157057a83a97801f9e726ed8051fb1d2231

fix: doc test

view details

VillSnow

commit sha 27b06f10dc01319c449d0f8c04218136431938c8

update: doc comment

view details

VillSnow

commit sha 8cc6998cd460f8534b3cf643a7620354bd007856

add: tests

view details

Anirban

commit sha 886f81e1d0883f67fbc81b8ece61b1c33f6923d2

Fix sentence structure Fixed grammar and sentence structure on appropriate instances.

view details

Dylan McKay

commit sha 50f20ec576ae72ceff6bf5a50c940cf574990e56

[AVR] Update the rust-lang/llvm-project submodule to include AVR fixes recently merged This commit updates rustc's LLVM submodule to include new AVR-specific fixes recently merged on the Rust LLVM 'rustc/10.0-2020-05-05' branch. All of these cherry-picked commits exist in upstream LLVM and were cherry-picked into Rust's LLVM fork in commit 6c040dd86ed. |- 6c040dd86ed Merge pull request #66 from dylanmckay/avr-pick-upstream-llvm-fixes |- 12dfdd3aed7 [AVR] Rewrite the function calling convention. |- 118ac53f12b [AVR] Don't adjust for instruction size |- bc27c282e13 [AVR] Fix miscompilation of zext + add |- cfbe205a7e8 [AVR] Remove faulty stack pushing behavior |- 143e1469e96 [AVR] Fix stack size in functions with a frame pointer |- 6b2445d841e [LLVM][AVR] Support for R_AVR_6 fixup |- 93ee4da19cf [AVR] Fix I/O instructions on XMEGA |- 962c2415ffb [AVR] Do not place functions in .progmem.data |- 65b8b170aef [AVR] Do not use divmod calls for bigger integers |- 93a3b595d1c [AVR] Generalize the previous interrupt bugfix to signal |- handlers too |- cc4286349b4 [AVR] Respect the 'interrupt' function attribute |- 954d0a92205 [AVR] Fix reads of uninitialized variables from constructor of AVRSubtarget |- 1c0ddae73c9 [AVR] Fix read of uninitialized variable AVRSubtarget:::ELFArch |- 0ed0823fe60 [AVR] Fix incorrect register state for LDRdPtr |- 96075fc433d [AVR] Don't adjust addresses by 2 for absolute values |- 6dfc55ba53b [AVR] Use correct register class for mul instructions These changes include both correctness fixes and LLVM assertion error fixes. Once all of these commits have been cherry-picked, all of the LLVM plumbing for rust-lang/master to compile the AVR blink program will be in place. Once this commit is merged, only PR rust-lang/rust#73270 will be blocking successful compilation and emission of the AVR LED blink program.

view details

Keno Fischer

commit sha 0c88dd663a7095ccc405a2036047a90981137a51

Update Box::from_raw example to generalize better I know very little about rust, so I saw this example and tried to generalize it by writing, ``` let layout = Layout::new::<T>(); let new_obj = unsafe { let ptr = alloc(layout) as *mut T; *ptr = obj; Box::from_raw(ptr) }; ``` for some more complicated `T`, which ended up crashing with SIGSEGV, because it tried to `drop_in_place` the previous object in `ptr` which is of course garbage. I also added a comment that explains why `.write` is used, but I think adding that comment is optional and may be too verbose here. I do however think that changing this example is a good idea to suggest the correct generalization. `.write` is also used in most of the rest of the documentation here, even if the example is `i32`, so it would additionally be more consistent.

view details

Anirban

commit sha 3b5d7f8cf66c6704d36b021f7173241d6351ad32

Minor correction to sentence structure

view details

David Hewitt

commit sha 6b95f3102d657a5cd0549213a073b28c7e0fe609

Add `format_args_capture` feature

view details

push time in 16 days

Pull request review commentrust-lang/rust

consult dlerror() only if a dl*() call fails

 mod dl {             // dlerror isn't thread safe, so we need to lock around this entire             // sequence             let _guard = (*LOCK).lock();++            // dlerror reports the most recent failure that occured during a+            // dynamic linking operation and then clears that error; we call+            // once in advance of our operation in an attempt to discard any+            // stale prior error report that may exist:             let _old_error = libc::dlerror();              let result = f(); -            let last_error = libc::dlerror() as *const _;-            if ptr::null() == last_error {+            // We should only check dlerror() in the event that the operation+            // fails, which we determine by checking for a NULL return.  This+            // covers at least dlopen() and dlsym().

For dlsym at least, the current approach is explicitly recommended on linux and seems to be necessary on illumos as well, since NULL can indicate either an error condition or a "symbol not found" error. We should be checking the return value of dlopen, but we will need to find a workaround here.

jclulow

comment created time in 16 days

push eventecstatic-morse/rust

Caleb Zulawski

commit sha 8e899b1cbe6209842e112f0b7ec450a3cdfdb36d

Don't implement Fn* for unsafe #[target_feature] functions

view details

Vadim Petrochenkov

commit sha 7055c23d2cb3baabbae6af7ab196e43035260856

ast_pretty: Pass some token streams and trees by reference

view details

David Hewitt

commit sha a1217cb29de22aae3cda717e78d1edd3e9d8ffd1

Add `format_args_capture` to the unstable book

view details

Tomasz Miąsko

commit sha 14d03702735ccca48f5b954db6c01e9cedb14f29

Remove defunct `-Z print-region-graph`

view details

James Box

commit sha 7231e575461d1246c247b2ac3e97c1adcab49737

Fix wording for anonymous parameter name help

view details

pierwill

commit sha 4595fa8a1baf95b0a19aae3d84e945344d8f8a44

Fix comma in debug_assert! docs

view details

Ivan Tham

commit sha 0e6f1093be08949b6ac4ba3d92ad4e97d0137dc5

Add preamable on rustc-attrs doc discussion

view details

Alexis Bourget

commit sha e611a3fb8423f178e856813fc1a1f2397980bd8a

Apply suggestions from code review

view details

Charles Lew

commit sha e8f5785bfc3123b67e79e509c76259062e214b97

Split and expand nonstandard-style lints unicode unit test.

view details

Dylan MacKenzie

commit sha 3c5ee3300f6c88f3d984d62ce704d17b7432f29c

Update tests

view details

Alexis Bourget

commit sha dfd454bd3843c4f4dee2e943297bf3d208252dc6

Apply suggestions, reformulating some paragraphs and improving some examples

view details

CAD97

commit sha db539c649866d9a25cb18a741436b3086b5d6e04

Use raw_ref_op in A|Rc::as_ptr

view details

CAD97

commit sha e4bdf47f4c0773bba93f50900612242b929eca0b

Do not require ptr validity in rc::data_offset

view details

CAD97

commit sha d8a9c61e1a23b73c04d3058a11d1b8b2a46d635e

Use impl for Weak::as_ptr that works for unsized T

view details

Alexis Bourget

commit sha 4224313e2bc3fc08e5eee0519d7b5813c3cad580

Fix small nits

view details

pierwill

commit sha 49c1018d139746f926f1af03d1d4282e0fed7115

Fix markdown rendering in librustc_lexer docs Use back-ticks instead of quotation marks in docs for the block comment variant of TokenKind.

view details

pierwill

commit sha 40c74a7eb709f3f072d35b4264c614a9a8f6c2f9

Edit cursor.prev() method docs in lexer Fix missing punctuation

view details

pierwill

commit sha 49662726afdd6f4538bada73db771b939d92bd22

Add newline to rustc MultiSpan docs Also adds back-ticks when referring to the contents of this collection.

view details

Alex Crichton

commit sha 3dfbf0bc738d1ba4ee0f084ce3f32074fceee3bb

rustbuild: Move compiler-builtins build logic to manifest This commit moves the compiler-builtins-specific build logic from `src/bootstrap/bin/rustc.rs` into the workspace `Cargo.toml`'s `[profile]` configuration. Now that rust-lang/cargo#7253 is fixed we can ensure that Cargo knows about debug assertions settings, and it can also be configured to specifically disable debug assertions unconditionally for compiler-builtins. This should improve rebuild logic when debug-assertions settings change and also improve build-std integration where Cargo externally now has an avenue to learn how to build compiler-builtins as well.

view details

Ivan Tham

commit sha 49b4804d291bc8cc93e7b4b8c24f344aa3e3f484

Ignore example compile in rustc-attrs doc

view details

push time in 16 days

pull request commentrust-lang/rust

do not try fetching the ancestors of errored trait impls

r? @matthewjasper

lcnr

comment created time in 16 days

pull request commentrust-lang/rust

consult dlerror() only if a dl*() call fails

r=me with nits addressed. I don't think you need to change the existing CStr conversion, although to_string_lossy would be more appropriate here.

jclulow

comment created time in 16 days

Pull request review commentrust-lang/rust

consult dlerror() only if a dl*() call fails

 mod dl {             // dlerror isn't thread safe, so we need to lock around this entire             // sequence             let _guard = (*LOCK).lock();++            // dlerror reports the most recent failure that occured during a+            // dynamic linking operation and then clears that error; we call+            // once in advance of our operation in an attempt to discard any+            // stale prior error report that may exist:             let _old_error = libc::dlerror();              let result = f(); -            let last_error = libc::dlerror() as *const _;-            if ptr::null() == last_error {+            // We should only check dlerror() in the event that the operation+            // fails, which we determine by checking for a NULL return.  This+            // covers at least dlopen() and dlsym().

Can you document these semantics at the function level? Specifically, if f returns a null pointer, this function returns Err with the string in dlerror.

Also, just to be sure, do all the functions we pass to this helper return NULL and only NULL to indicate an error? There's no (void *) 1 weirdness or something?

jclulow

comment created time in 16 days

Pull request review commentrust-lang/rust

consult dlerror() only if a dl*() call fails

 mod dl {             // dlerror isn't thread safe, so we need to lock around this entire             // sequence             let _guard = (*LOCK).lock();++            // dlerror reports the most recent failure that occured during a+            // dynamic linking operation and then clears that error; we call+            // once in advance of our operation in an attempt to discard any+            // stale prior error report that may exist:             let _old_error = libc::dlerror();              let result = f(); -            let last_error = libc::dlerror() as *const _;-            if ptr::null() == last_error {+            // We should only check dlerror() in the event that the operation+            // fails, which we determine by checking for a NULL return.  This+            // covers at least dlopen() and dlsym().+            //+            // While we are able to exclude other callers within this library,+            // we are not able to exclude external callers such as those in the+            // system libraries.  If dynamic linking activity is induced in+            // another thread, it may destroy our dlerror() report or it may+            // inject one that does not apply to us -- this error report must be+            // treated as advisory.+            if ptr::null() != result {                 Ok(result)             } else {

Since the else block now has a condition inside, could you switch to an early return for the happy path?

jclulow

comment created time in 16 days

Pull request review commentrust-lang/rust

consult dlerror() only if a dl*() call fails

 mod dl {             // dlerror isn't thread safe, so we need to lock around this entire             // sequence             let _guard = (*LOCK).lock();++            // dlerror reports the most recent failure that occured during a+            // dynamic linking operation and then clears that error; we call+            // once in advance of our operation in an attempt to discard any+            // stale prior error report that may exist:             let _old_error = libc::dlerror();

As @ollie27 said, there's no need to do this anymore if we don't use the return value of dlerror to determine whether an error occurred.

jclulow

comment created time in 16 days

pull request commentrust-lang/rust

Bail out early from `truncate` if the new length is equal to the old

I've replaced Vec::clear with the obvious implementation. The Vec methods in question are now faster or the same for all use-cases I've looked at. Notably, an optimized version of Vec::clone_from has one fewer branch. Unlike a bare truncate, I can actually see Vec::clone_from being called in a tight loop.

Old:

# %bb.0:
	push	rbp
	push	r15
	push	r14
	push	r13
	push	r12
	push	rbx
	push	rax
	mov	r12, rsi
	mov	r15, qword ptr [rsi + 16]
	mov	r13, qword ptr [rdi + 16]
	cmp	r13, r15
	jb	.LBB2_6             # EXTRA BRANCH HERE
# %bb.1:
	mov	rbx, qword ptr [rdi]
	mov	qword ptr [rdi + 16], r15
	jne	.LBB2_3      
# %bb.2:
	mov	r13, r15
	jmp	.LBB2_8

.LBB2_3:
	mov	qword ptr [rsp], rdi    # 8-byte Spill
	lea	rbp, [8*r15]
	shl	r13, 3
	mov	r14, qword ptr [rip + __rust_dealloc@GOTPCREL]

.LBB2_4:                                # =>This Inner Loop Header: Depth=1
	mov	rdi, qword ptr [rbx + rbp]
	mov	esi, 4
	mov	edx, 4
	call	r14
	add	rbp, 8
	cmp	r13, rbp
	jne	.LBB2_4
# %bb.5:
	mov	rdi, qword ptr [rsp]    # 8-byte Reload
	mov	r13, qword ptr [rdi + 16]

.LBB2_6:
	cmp	r15, r13
	jb	.LBB2_17
# %bb.7:
	mov	rbx, qword ptr [rdi]

.LBB2_8:
	mov	rcx, qword ptr [r12]
	lea	rsi, [rcx + 8*r13]
	sub	r15, r13
	test	r13, r13
	je	.LBB2_16
# %bb.9:
	lea	rdx, [r13 - 1]
	mov	r8d, r13d
	and	r8d, 3
	cmp	rdx, 3
	jae	.LBB2_11
# %bb.10:
	xor	edx, edx
	jmp	.LBB2_13

.LBB2_11:
	sub	r13, r8
	xor	edx, edx

.LBB2_12:                               # =>This Inner Loop Header: Depth=1
	mov	rax, qword ptr [rbx + 8*rdx]
	mov	rbp, qword ptr [rcx + 8*rdx]
	mov	ebp, dword ptr [rbp]
	mov	dword ptr [rax], ebp
	mov	rax, qword ptr [rbx + 8*rdx + 8]
	mov	rbp, qword ptr [rcx + 8*rdx + 8]
	mov	ebp, dword ptr [rbp]
	mov	dword ptr [rax], ebp
	mov	rax, qword ptr [rbx + 8*rdx + 16]
	mov	rbp, qword ptr [rcx + 8*rdx + 16]
	mov	ebp, dword ptr [rbp]
	mov	dword ptr [rax], ebp
	mov	rax, qword ptr [rbx + 8*rdx + 24]
	mov	rbp, qword ptr [rcx + 8*rdx + 24]
	add	rdx, 4
	mov	ebp, dword ptr [rbp]
	mov	dword ptr [rax], ebp
	cmp	r13, rdx
	jne	.LBB2_12

.LBB2_13:
	test	r8, r8
	je	.LBB2_16
# %bb.14:
	lea	rcx, [rcx + 8*rdx]
	lea	rdx, [rbx + 8*rdx]
	xor	eax, eax

.LBB2_15:                               # =>This Inner Loop Header: Depth=1
	mov	rbp, qword ptr [rdx + 8*rax]
	mov	rbx, qword ptr [rcx + 8*rax]
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	add	rax, 1
	cmp	r8, rax
	jne	.LBB2_15

.LBB2_16:
	mov	rdx, r15
	add	rsp, 8
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	jmp	alloc::vec::Vec<T>::extend_from_slice # TAILCALL

.LBB2_17:
	lea	rdx, [rip + .L__unnamed_1]
	mov	rdi, r13
	mov	rsi, r15
	call	qword ptr [rip + core::slice::slice_index_len_fail@GOTPCREL]
	ud2
                                        # -- End function

New:

# %bb.0:
	push	rbp
	push	r15
	push	r14
	push	r13
	push	r12
	push	rbx
	push	rax
	mov	r12, rsi
	mov	r15, qword ptr [rsi + 16]
	mov	r13, qword ptr [rdi + 16]
	cmp	r13, r15
	jbe	.LBB3_4    
# %bb.1:
	mov	rbx, qword ptr [rdi]
	mov	qword ptr [rsp], rdi    # 8-byte Spill
	mov	qword ptr [rdi + 16], r15
	lea	rbp, [8*r15]
	shl	r13, 3
	mov	r14, qword ptr [rip + __rust_dealloc@GOTPCREL] 

.LBB3_2:                                # =>This Inner Loop Header: Depth=1
	mov	rdi, qword ptr [rbx + rbp]
	mov	esi, 4
	mov	edx, 4
	call	r14
	add	rbp, 8
	cmp	r13, rbp
	jne	.LBB3_2
# %bb.3:
	mov	rdi, qword ptr [rsp]    # 8-byte Reload
	mov	r13, qword ptr [rdi + 16]

.LBB3_4:
	mov	rdx, r15
	sub	rdx, r13
	jb	.LBB3_14
# %bb.5:
	mov	r9, qword ptr [r12]
	lea	rsi, [r9 + 8*r13]
	test	r13, r13
	je	.LBB3_13
# %bb.6:
	mov	rcx, qword ptr [rdi]
	lea	rax, [r13 - 1]
	mov	r8d, r13d
	and	r8d, 3
	cmp	rax, 3
	jae	.LBB3_8
# %bb.7:
	xor	eax, eax
	jmp	.LBB3_10

.LBB3_8:
	sub	r13, r8
	xor	eax, eax

.LBB3_9:                                # =>This Inner Loop Header: Depth=1
	mov	rbp, qword ptr [rcx + 8*rax]
	mov	rbx, qword ptr [r9 + 8*rax]
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	mov	rbp, qword ptr [rcx + 8*rax + 8]
	mov	rbx, qword ptr [r9 + 8*rax + 8]
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	mov	rbp, qword ptr [rcx + 8*rax + 16]
	mov	rbx, qword ptr [r9 + 8*rax + 16]
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	mov	rbp, qword ptr [rcx + 8*rax + 24]
	mov	rbx, qword ptr [r9 + 8*rax + 24]
	add	rax, 4
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	cmp	r13, rax
	jne	.LBB3_9

.LBB3_10:
	test	r8, r8
	je	.LBB3_13
# %bb.11:
	lea	r9, [r9 + 8*rax]
	lea	rax, [rcx + 8*rax]
	xor	ecx, ecx

.LBB3_12:                               # =>This Inner Loop Header: Depth=1
	mov	rbp, qword ptr [rax + 8*rcx]
	mov	rbx, qword ptr [r9 + 8*rcx]
	mov	ebx, dword ptr [rbx]
	mov	dword ptr [rbp], ebx
	add	rcx, 1
	cmp	r8, rcx
	jne	.LBB3_12

.LBB3_13:
	add	rsp, 8
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	jmp	alloc::vec::Vec<T>::extend_from_slice # TAILCALL

.LBB3_14:
	lea	rdx, [rip + .L__unnamed_1]
	mov	rdi, r13
	mov	rsi, r15
	call	qword ptr [rip + core::slice::slice_index_len_fail@GOTPCREL]
	ud2
                                        # -- End function
ecstatic-morse

comment created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha d88f09ba9720df92610c66ac81ea69fd8f964a7e

Implement `Vec::clear` by hand The new version of `truncate` compiles up a branch when called with a constant `0` and `T: !Drop`.

view details

push time in a month

issue commentrust-lang/rust

`VecDeque` implementation creates a slice pointing to possibly uninitialized memory

This one seems so obvious that I'm wondering if I've overlooked something.

I need to stop hedging :smile:.

I also had assumed that the question of whether &T required T to be valid was more settled than the discussion in rust-lang/unsafe-code-guidelines#77 suggests. With that in mind, how do we want to prioritize this? I think it's not unprecedented for the standard library to rely on behavior that is technically undefined when there is active discussion about the rules and we aren't relying on that property for optimizations. That seems to be the case here?

ecstatic-morse

comment created time in a month

issue commentrust-lang/rust

Handle generic associated constants in const qualification for structural match

@lcnr Sorry I missed your comment.

it should be possible to change ConstQualifs::custom_eq to Option<&'tcx [Ty<'tcx>]> where all the Ty<'tcx> are projections/opaque types which are required to be structurally match but are still too generic.

This is indeed possible, although not with the current dataflow framework, which only works on BitSets of some index type. We would need to extend it to work on arbitrary lattices (in this case the set of all projections/opaque types ordered by inclusion). I've had this on the backburner for some time, but I might get around to it soon.

If we were to go this route, const qualification will become slower and more memory hungry, so like you I would prefer to avoid it. Given that, it seems we would need to break code like this to convert fully to a const-qualification-based approach. Presumably, having two layers of associated constants in a pattern is presumably something very few users care about. However, I don't think this meets the requirements for a breaking change, since the code isn't actually unsound.

ecstatic-morse

comment created time in a month

issue openedrust-lang/rust

`VecDeque` implementation creates a slice pointing to possibly uninitialized memory

VecDeque has an internal method called buffer_as_slice, which returns an &[T] containing the entire capacity of the VecDeque. This is undefined behavior if the VecDeque is not full, since some elements of the backing RawVec may be uninitialized. However, this invariant is not documented on buffer_as_slice and is not respected in practice. For example, VecDeque::iter calls buffer_on_slice unconditionally:

https://github.com/rust-lang/rust/blob/34c5cd9a64d8537236626c4ccbed39a924cd38e2/src/liballoc/collections/vec_deque.rs#L959-L962

This one seems so obvious that I'm wondering if I've overlooked something. cc @rust-lang/wg-unsafe-code-guidelines

created time in a month

pull request commentrust-lang/rust

Bail out early from `truncate` if the new length is equal to the old

Seems like this results in an additional branch for Vec::truncate(0) (AKA Vec::clear) for vectors of Copy types. In the code that motivated this PR, equality was the common case, and this change does result in slightly better code when the elements are not Copy (note the extra branch in foo).

Maybe we just want to close this? Or I could implement Vec::clear by hand? I don't expect it's common for people to need Vec::truncate in a tight loop.

ecstatic-morse

comment created time in a month

pull request commentrust-lang/rust

[WIP] Support MIR dataflow problems on arbitrary lattices

@bors try @rust-timer queue

ecstatic-morse

comment created time in a month

PR opened rust-lang/rust

Bail out early from `truncate` if the new length is equal to the old

truncate should do nothing for collections if the new length is equal to the current length, but this is not explicitly stated in the code. Instead, control flow continues in this case until an empty slice is passed to drop_in_place. While this is equivalent and likely optimizes to the same code, it is not as clear.

+10 -8

0 comment

3 changed files

pr created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 8d0eded7ec508b40681979cb2bc8a9676be2752d

Don't truncate if new length is equal to old `truncate` should do nothing for collections if the new length is equal to the current length, but this was not reflected in the code. Instead, control flow continued until an empty slice was passed to `drop_in_place`.

view details

push time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 698e870f75710152309158342fd18461531cc0fb

Stop adding unreachable basic blocks to dataflow work queue Also adds some debug assertions to prevent API consumers from visiting those basic blocks by accident.

view details

push time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 0d3deca34f25a29b19dd2d2ab03a62e9b62614ab

WIP

view details

push time in a month

push eventecstatic-morse/rust

push time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha d3357a9a26f602c7d03c6f6b4b4d288a6648dd81

WIP

view details

Dylan MacKenzie

commit sha 5f849400e1426c02d2db016ae5bfad8c353af18f

pplattice

view details

push time in a month

create barnchecstatic-morse/rust

branch : truncate-len-eq

created branch time in a month

PR opened rust-lang/rust

[WIP] Support MIR dataflow problems on arbitrary lattices

Still a ways off. Needs a perf run for the dynamic dispatch.

r? @ghost

+540 -328

0 comment

19 changed files

pr created time in a month

create barnchecstatic-morse/rust

branch : dataflow-lattice

created branch time in a month

PR opened rust-lang/rust

Stop processing unreachable blocks when solving dataflow

...instead we debug_assert that the user is not checking the dataflow state for an unreachable block. This resolves a FIXME in the dataflow engine. The old behavior was an artifact of the previous dataflow framework. Things should run a tiny bit faster now, but I suspect not enough to show up in benchmarks. AFAIK, only the generator transform runs dataflow on MIR with unreachable basic blocks.

This PR also adds some utility methods to mir::traversal.

r? @pnkfelix

+42 -14

0 comment

5 changed files

pr created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha efe634f14c20661216c57322b319c1cac1f9704f

Add `reachable` and friends to `mir::traversal` module

view details

Dylan MacKenzie

commit sha a971007047bc4dd1814b11bcd0bb1db5280c2521

Stop adding unreachable basic blocks to dataflow work queue Also adds some debug assertions to prevent API consumers from visiting those basic blocks by accident.

view details

push time in a month

create barnchecstatic-morse/rust

branch : dataflow-unreachable

created branch time in a month

startedbodil/smartstring

started time in a month

pull request commentrust-lang/rust

Optimize is_ascii for str and [u8].

I would have added a fast path for when slice.len() < mem::size_of::<usize>() to the align_to version since your version has a similar check that makes it fast on the small benchmark. I will note that the margin of error for both versions overlaps, but I would call your version meaningfully more efficient on x86 at least. Thanks for doing the work.

thomcc

comment created time in a month

pull request commentrust-lang/rust

Optimize is_ascii for str and [u8].

Simple code is good code, and people running ARM may also want to check whether their strings are ASCII-only. If your more complex version is meaningfully more efficient, then fine, but I suspect it's not.

thomcc

comment created time in a month

pull request commentrust-lang/rust

Optimize is_ascii for str and [u8].

You should have a look at slice::align_to.

thomcc

comment created time in a month

pull request commentrust-lang/rust

Clean up errors caused by `::` -> `:` typos

I'm not familiar with this part of the code base.

r? @petrochenkov maybe?

estebank

comment created time in a month

pull request commentrust-lang/rust

Eliminate `ObligationCauseData`.

Is there a semantic difference between dummy and misc? We could try to unify the two instead.

nnethercote

comment created time in a month

pull request commentrust-lang/rust

Avoid `unwrap_or_else` in `RawVec::allocate_in`.

@bors r=Amanieu

nnethercote

comment created time in a month

PullRequestEvent

PR closed rust-lang/rust

Avoid `unwrap_or_else` in `RawVec::allocate_in`. S-waiting-on-author

This reduces the amount of LLVM IR generated by up to 1 or 2%.

r? @Amanieu

+14 -3

18 comments

1 changed file

nnethercote

pr closed time in a month

pull request commentrust-lang/rust

Avoid `unwrap_or_else` in `RawVec::allocate_in`.

@bors r-

nnethercote

comment created time in a month

pull request commentrust-lang/rust

Avoid `unwrap_or_else` in `RawVec::allocate_in`.

Or maybe bors is just borked? This still isn't in the queue.

nnethercote

comment created time in a month

pull request commentrust-lang/rust

Avoid `unwrap_or_else` in `RawVec::allocate_in`.

@bors r=Amanieu

(@Manishearth I think "retry" retried the r-?)

nnethercote

comment created time in a month

pull request commentrust-lang/rust

Handle inactive enum variants in `MaybeUninitializedPlaces`

@bors rollup=never (perf)

ecstatic-morse

comment created time in a month

pull request commentrust-lang/rust

Handle inactive enum variants in `MaybeUninitializedPlaces`

r? @oli-obk cc @eddyb

ecstatic-morse

comment created time in a month

Pull request review commentrust-lang/rust

Const floating point bitcasts and classification

+// -Zmir-opt-level=0+// run-pass++#![feature(const_panic)]+#![feature(const_if_match)]+#![feature(const_float_bits_conv)]+#![feature(const_float_classify)]++// Don't promote+const fn nop<T>(x: T) -> T { x }++macro_rules! const_assert {+    ($a:expr, $b:expr) => {+        {+            const _: () = assert!($a == $b);+            assert_eq!(nop($a), nop($b));+        }+    };+}++macro_rules! suite {+    ( $( $tt:tt )* ) => {+        fn f32() {+            suite_inner!(f32 $($tt)*);+        }++        fn f64() {+            suite_inner!(f64 $($tt)*);+        }+    }++}++macro_rules! suite_inner {+    (+        $ty:ident [$( $fn:ident ),*]+        $val:expr => [$($out:ident),*]++        $( $tail:tt )*+    ) => {+        $( const_assert!($ty::$fn($val), $out); )*+        suite_inner!($ty [$($fn),*] $($tail)*)+    };++    ( $ty:ident [$( $fn:ident ),*]) => {};+}++suite! {+                   [is_nan, is_infinite, is_finite, is_normal, is_sign_positive, is_sign_negative]+     -0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+      0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+            1.0 => [ false,       false,      true,      true,             true,            false]+           -1.0 => [ false,       false,      true,      true,            false,             true]+            0.0 => [ false,       false,      true,     false,             true,            false]+           -0.0 => [ false,       false,      true,     false,            false,             true]+      1.0 / 0.0 => [ false,        true,     false,     false,             true,            false]+     -1.0 / 0.0 => [ false,        true,     false,     false,            false,             true]

This is LLVMs const propagation. I think I need to rewrite this test to not assume anything about NaN signedness, since it's likely to fail on other platforms.

ecstatic-morse

comment created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha eb4d28bce0a73ddbdbcd107dd7875ddd97a603d8

Bless mir-opt tests

view details

push time in a month

pull request commentrust-lang/rust

Handle inactive enum variants in `MaybeUninitializedPlaces`

How does interact with generators?

Hey, you're not a :ghost: :smile:!

The generator transform doesn't use MaybeUninitializedLocals to compute generator saved locals, and it does drop elaboration with DropShimElaborator , which also doesn't use MaybeUninitializedLocals. Only Elaborator, which seems to be the "general purpose" drop elaborator uses it. Furthermore, apply_discriminant_switch_effect doesn't get called for TyKind::Generators, so I don't believe that this affects generators any more than regular functions. I don't know what the benefits might be from changing that last part.

ecstatic-morse

comment created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha ca8678b23e5f49c65da1e0d2aa01d3fa0d5178e9

Handle inactive enum variants in `MaybeUninitializedPlaces`

view details

Dylan MacKenzie

commit sha a6de429eb01f25533f911f600a583095cf36b36a

Bless mir-opt tests

view details

push time in a month

pull request commentrust-lang/rust

Handle inactive enum variants in `MaybeUninitializedPlaces`

@bors try @rust-timer queue

ecstatic-morse

comment created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 24738da9cb344b42c6089ec1f1a1e1cac07349ef

Handle inactive enum variants in `MaybeUninitializedPlaces`

view details

Dylan MacKenzie

commit sha 7f8b034f63e2914164a1a2ef52b077272363f3fb

Bless mir-opt tests

view details

push time in a month

PR opened rust-lang/rust

Handle inactive enum variants in `MaybeUninitializedPlaces`

cc #69715.

r? @ghost

+124 -39

0 comment

7 changed files

pr created time in a month

create barnchecstatic-morse/rust

branch : discr-switch-uninit

created branch time in a month

Pull request review commentrust-lang/rust

Const floating point bitcasts and classification

+// -Zmir-opt-level=0+// run-pass++#![feature(const_panic)]+#![feature(const_if_match)]+#![feature(const_float_bits_conv)]+#![feature(const_float_classify)]++// Don't promote+const fn nop<T>(x: T) -> T { x }++macro_rules! const_assert {+    ($a:expr, $b:expr) => {+        {+            const _: () = assert!($a == $b);+            assert_eq!(nop($a), nop($b));+        }+    };+}++macro_rules! suite {+    ( $( $tt:tt )* ) => {+        fn f32() {+            suite_inner!(f32 $($tt)*);+        }++        fn f64() {+            suite_inner!(f64 $($tt)*);+        }+    }++}++macro_rules! suite_inner {+    (+        $ty:ident [$( $fn:ident ),*]+        $val:expr => [$($out:ident),*]++        $( $tail:tt )*+    ) => {+        $( const_assert!($ty::$fn($val), $out); )*+        suite_inner!($ty [$($fn),*] $($tail)*)+    };++    ( $ty:ident [$( $fn:ident ),*]) => {};+}++suite! {+                   [is_nan, is_infinite, is_finite, is_normal, is_sign_positive, is_sign_negative]+     -0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+      0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+            1.0 => [ false,       false,      true,      true,             true,            false]+           -1.0 => [ false,       false,      true,      true,            false,             true]+            0.0 => [ false,       false,      true,     false,             true,            false]+           -0.0 => [ false,       false,      true,     false,            false,             true]+      1.0 / 0.0 => [ false,        true,     false,     false,             true,            false]+     -1.0 / 0.0 => [ false,        true,     false,     false,            false,             true]

Oh, one interesting note is that -0.0 / 0.0 happens to have a positive sign both on Miri and in x86_64 release mode. This is not guaranteed anywhere, and it might differ between platforms (especially in debug mode where const propagation doesn't apply).

ecstatic-morse

comment created time in a month

Pull request review commentrust-lang/rust

Const floating point bitcasts and classification

+// -Zmir-opt-level=0+// run-pass++#![feature(const_panic)]+#![feature(const_if_match)]+#![feature(const_float_bits_conv)]+#![feature(const_float_classify)]++// Don't promote+const fn nop<T>(x: T) -> T { x }++macro_rules! const_assert {+    ($a:expr) => {+        {+            const _: () = assert!($a);+            assert!(nop($a));+        }+    };+    ($a:expr, $b:expr) => {+        {+            const _: () = assert!($a == $b);+            assert_eq!(nop($a), nop($b));+        }+    };+}++fn f32() {+    const_assert!((1f32).to_bits(), 0x3f800000);+    const_assert!(u32::from_be_bytes(1f32.to_be_bytes()), 0x3f800000);+    const_assert!((12.5f32).to_bits(), 0x41480000);+    const_assert!(u32::from_le_bytes(12.5f32.to_le_bytes()), 0x41480000);+    const_assert!((1337f32).to_bits(), 0x44a72000);+    const_assert!(u32::from_ne_bytes(1337f32.to_ne_bytes()), 0x44a72000);+    const_assert!((-14.25f32).to_bits(), 0xc1640000);+    const_assert!(f32::from_bits(0x3f800000), 1.0);+    const_assert!(f32::from_be_bytes(0x3f800000u32.to_be_bytes()), 1.0);+    const_assert!(f32::from_bits(0x41480000), 12.5);+    const_assert!(f32::from_le_bytes(0x41480000u32.to_le_bytes()), 12.5);+    const_assert!(f32::from_bits(0x44a72000), 1337.0);+    const_assert!(f32::from_ne_bytes(0x44a72000u32.to_ne_bytes()), 1337.0);+    const_assert!(f32::from_bits(0xc1640000), -14.25);++    // Check that NaNs roundtrip their bits regardless of signalingness+    // 0xA is 0b1010; 0x5 is 0b0101 -- so these two together clobbers all the mantissa bits+    const MASKED_NAN1: u32 = f32::NAN.to_bits() ^ 0x002A_AAAA;+    const MASKED_NAN2: u32 = f32::NAN.to_bits() ^ 0x0055_5555;++    const_assert!(f32::from_bits(MASKED_NAN1).is_nan());+    const_assert!(f32::from_bits(MASKED_NAN1).is_nan());++    // LLVM does not guarantee that loads and stores of NaNs preserve their exact bit pattern.+    // In practice, this seems to only cause a problem on x86, since the most widely used calling+    // convention mandates that floating point values are returned on the x87 FPU stack. See #73328.+    if !cfg!(target_arch = "x86") {

I believe so. It's used this way in other tests and the code from what I can tell. I don't think we have documentation with the possible values of target_arch, however.

ecstatic-morse

comment created time in a month

Pull request review commentrust-lang/rust

Const floating point bitcasts and classification

+// -Zmir-opt-level=0+// run-pass++#![feature(const_panic)]+#![feature(const_if_match)]+#![feature(const_float_bits_conv)]+#![feature(const_float_classify)]++// Don't promote+const fn nop<T>(x: T) -> T { x }++macro_rules! const_assert {+    ($a:expr, $b:expr) => {+        {+            const _: () = assert!($a == $b);+            assert_eq!(nop($a), nop($b));+        }+    };+}++macro_rules! suite {+    ( $( $tt:tt )* ) => {+        fn f32() {+            suite_inner!(f32 $($tt)*);+        }++        fn f64() {+            suite_inner!(f64 $($tt)*);+        }+    }++}++macro_rules! suite_inner {+    (+        $ty:ident [$( $fn:ident ),*]+        $val:expr => [$($out:ident),*]++        $( $tail:tt )*+    ) => {+        $( const_assert!($ty::$fn($val), $out); )*+        suite_inner!($ty [$($fn),*] $($tail)*)+    };++    ( $ty:ident [$( $fn:ident ),*]) => {};+}++suite! {+                   [is_nan, is_infinite, is_finite, is_normal, is_sign_positive, is_sign_negative]+     -0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+      0.0 / 0.0 => [  true,       false,     false,     false,             true,            false]+            1.0 => [ false,       false,      true,      true,             true,            false]+           -1.0 => [ false,       false,      true,      true,            false,             true]+            0.0 => [ false,       false,      true,     false,             true,            false]+           -0.0 => [ false,       false,      true,     false,            false,             true]+      1.0 / 0.0 => [ false,        true,     false,     false,             true,            false]+     -1.0 / 0.0 => [ false,        true,     false,     false,            false,             true]

If you figure out how to add that to the macro then sure. Since they're defined as 0 / 0, 1 / 0 and -1 / 0 respectively I don't think it's important.

ecstatic-morse

comment created time in a month

push eventecstatic-morse/rust

Dylan MacKenzie

commit sha 426ece4b2a51c8b6feae0cb8431e0bbb33f235d7

Remove outdated feature gates

view details

push time in a month

issue commentrust-lang/lang-team

const-evaluation

const_if_match and const_loop stabilization PR merged (rust-lang/rust#72437). On track for stabilization in 1.46.

nikomatsakis

comment created time in a month

push eventecstatic-morse/rust

Dylan DPC

commit sha fda594e6ae5c430475120944b8a0e92fe8f206a5

Rollup merge of #72890 - davidtwco:issue-66202-normalize-and-transparent-improper-ctypes, r=varkor improper ctypes: normalize return types and transparent structs Fixes #66202. See each commit individually (except the first which adds a test) for more detailed explanations on the changes made. In summary, this PR ensures that return types are normalized before being checked for FFI-safety, and that transparent newtype wrappers are FFI-safe if the type being wrapped is FFI-safe (often true previously, but not if, after substitution, all types in a transparent newtype were zero sized).

view details

Dylan DPC

commit sha 8addb2e684dfbe0cd2e16a769485a093f9b2de32

Rollup merge of #72897 - lcnr:structurally-match-normalize, r=pnkfelix normalize adt fields during structural match checking fixes #72896 currently only fixes the issue itself and compiles stage 1 libs. I believe we have to use something else to normalize the adt fields here, as I expect some partially resolved adts to cause problems :thinking: stage 1 libs and the test itself pass, not sure about the rest... Will spend some more time looking into it tomorrow. r? @pnkfelix cc @eddyb

view details

Dylan DPC

commit sha 024f025934a40056364be4a4da4f7e078b419f68

Rollup merge of #73005 - Aaron1011:fix/error-overflow, r=estebank Don't create impl candidates when obligation contains errors Fixes #72839 In PR #72621, trait selection was modified to no longer bail out early when an error type was encountered. This allowed us treat `ty::Error` as `Sized`, causing us to avoid emitting a spurious "not sized" error after a type error had already occured. However, this means that we may now try to match an impl candidate against the error type. Since the error type will unify with almost anything, this can cause us to infinitely recurse (eventually triggering an overflow) when trying to verify certain `where` clauses. This commit causes us to skip generating any impl candidates when an error type is involved.

view details

Dylan DPC

commit sha e1cd8c41a559276a2a8ff62085ded220cccb88f3

Rollup merge of #73023 - ayushmishra2005:remove_noisy_suggestion, r=davidtwco Remove noisy suggestion of hash_map Remove noisy suggestion of hash_map #72642 fixes #72642

view details

Dylan DPC

commit sha 0a77c8c2956259eb6811b51fac095c8ed21e6760

Rollup merge of #73070 - ayazhafiz:i/72819, r=nikomatsakis Add regression test for const generic ICE in #72819 Closes #72819

view details

Dylan DPC

commit sha e04e3c89cc08546c5c762ea915cb72d4069a733e

Rollup merge of #73157 - Aaron1011:where-oh-where-has-my-little-span-gone, r=ecstatic-morse Don't lose empty `where` clause when pretty-printing Previously, we would parse `struct Foo where;` and `struct Foo;` identically, leading to an 'empty' `where` clause being omitted during pretty printing. This will cause us to lose spans when proc-macros involved, since we will have a collected `where` token that does not appear in the pretty-printed item. We now explicitly track the presence of a `where` token during parsing, so that we can distinguish between `struct Foo where;` and `struct Foo;` during pretty-printing

view details

Dylan DPC

commit sha 2b8f1eccaa138a2a4af61356231c33d7d93ed993

Rollup merge of #73184 - mati865:fix-mingw-libs-order, r=petrochenkov Reoder order in which MinGW libs are linked to fix recent breakage Recent upstream mingw-w64 changes made libmsvcrt depend on libmingwex breaking compilation in some cases when using **external** MinGW. Applying this change to the master fixes nightly and stage{1,2} build. For stage0 one has to export `RUSTFLAGS_BOOTSTRAP='-C link-arg=-lmsvcrt'` until this PR lands in bootstrap compiler. Therefore I'm humbly asking to also backport it to the beta and update bootstrap compiler.

view details

Guillaume Gomez

commit sha dc230c06b226947a5a9980d2947118fd4a8ece9e

Clean up E0648 explanation

view details

Guillaume Gomez

commit sha 50a42fe5134fd8dbd5bc6df110654a31ee059a62

Create new error code E0762 for unterminated char literals

view details

Guillaume Gomez

commit sha 7bd87cfac2ca4c2c19b04018774b1fb1a9b39e48

Add tests for E0762

view details

Mihail Malo

commit sha 5859f6e4f792afb663ac2dc98191cca08ac9b4ae

Fix doctest template `saturating_add` example was not parameterized, but passed because the `u8` would saturate successfully

view details

Eric Huss

commit sha cd02052ad083ae0927a08483035b5dca214bdd0d

Fix emcc failure for wasm32.

view details

Manish Goregaokar

commit sha 34c6b38e68f2e88bcc6c943494a7c05d35a71f17

Add tests for macro@ and derive@

view details

Ralf Jung

commit sha f507748ce49f8e9ce5dc76bb7811a374c814923f

x.py: with --json-output, forward cargo's JSON

view details

bors

commit sha 449e8eaa286e407c9cd8cac655b77998fd53db6b

Auto merge of #73213 - ehuss:fix-emsdk, r=Mark-Simulacrum Fix emcc failure for wasm32. The wasm32 job is currently failing on CI with the error `ERROR: llc executable not found at /usr/bin/llc`. The issue is that https://github.com/emscripten-core/emsdk/pull/472 has changed how emsdk discovers its configuration. We were relying on the global behavior that would use a configuration from the home directory. However, it looks like emsdk is moving away from that approach. This change adds the necessary env var for emcc to find the correct configuration. There are a few alternate approaches this could take. The `--no-embedded` option could be passed to `emsdk activate` to use the old behavior, but it seems like they want to move away from that. Another option is to source `emsdk_env.sh`, which is how these env vars normally get set. I'm not entirely sure how to do that easily in a Dockerfile, though.

view details

Rich Kadel

commit sha d139a720a2c0ad7066c43edad6ec6c2aa9613740

Merge pull request #2 from rust-lang/master update from origin 2020-06-10

view details

Esteban Küber

commit sha c29b3fa1484c625bd34cb4d94fc76f36c6233447

On recursive ADT, provide indirection structured suggestion

view details

Esteban Küber

commit sha 7cde07e5cc5cfc1665dd64e4c06482c2f10b693a

review comments: only suggest one substitution

view details

Amanieu d'Antras

commit sha 2af53e9a15aed1e9798867c9233a722530d03177

Add -O compile flag to test

view details

Aaron Hill

commit sha 28946b3486d507418b8a4acb92d5e2baae193d65

Track span of function in method calls, and use this in #[track_caller] Fixes #69977 When we parse a chain of method calls like `foo.a().b().c()`, each `MethodCallExpr` gets assigned a span that starts at the beginning of the call chain (`foo`). While this is useful for diagnostics, it means that `Location::caller` will return the same location for every call in a call chain. This PR makes us separately record the span of the function name and arguments for a method call (e.g. `b()` in `foo.a().b().c()`). This `Span` is passed through HIR lowering and MIR building to `TerminatorKind::Call`, where it is used in preference to `Terminator.source_info.span` when determining `Location::caller`. This new span is also useful for diagnostics where we want to emphasize a particular method call - for an example, see https://github.com/rust-lang/rust/pull/72389#discussion_r436035990

view details

push time in a month

Pull request review commentrust-lang/rust

Const floating point bitcasts and classification

+// -Zmir-opt-level=0+// run-pass++#![feature(const_panic)]+#![feature(const_if_match)]+#![feature(const_float_bits_conv)]+#![feature(const_float_classify)]++// Don't promote+const fn nop<T>(x: T) -> T { x }++macro_rules! const_assert {+    ($a:expr) => {+        {+            const _: () = assert!($a);+            assert!(nop($a));+        }+    };+    ($a:expr, $b:expr) => {+        {+            const _: () = assert!($a == $b);+            assert_eq!(nop($a), nop($b));+        }+    };+}++fn f32() {+    const_assert!((1f32).to_bits(), 0x3f800000);+    const_assert!(u32::from_be_bytes(1f32.to_be_bytes()), 0x3f800000);+    const_assert!((12.5f32).to_bits(), 0x41480000);+    const_assert!(u32::from_le_bytes(12.5f32.to_le_bytes()), 0x41480000);+    const_assert!((1337f32).to_bits(), 0x44a72000);+    const_assert!(u32::from_ne_bytes(1337f32.to_ne_bytes()), 0x44a72000);+    const_assert!((-14.25f32).to_bits(), 0xc1640000);+    const_assert!(f32::from_bits(0x3f800000), 1.0);+    const_assert!(f32::from_be_bytes(0x3f800000u32.to_be_bytes()), 1.0);+    const_assert!(f32::from_bits(0x41480000), 12.5);+    const_assert!(f32::from_le_bytes(0x41480000u32.to_le_bytes()), 12.5);+    const_assert!(f32::from_bits(0x44a72000), 1337.0);+    const_assert!(f32::from_ne_bytes(0x44a72000u32.to_ne_bytes()), 1337.0);+    const_assert!(f32::from_bits(0xc1640000), -14.25);++    // Check that NaNs roundtrip their bits regardless of signalingness+    // 0xA is 0b1010; 0x5 is 0b0101 -- so these two together clobbers all the mantissa bits+    const MASKED_NAN1: u32 = f32::NAN.to_bits() ^ 0x002A_AAAA;+    const MASKED_NAN2: u32 = f32::NAN.to_bits() ^ 0x0055_5555;++    const_assert!(f32::from_bits(MASKED_NAN1).is_nan());+    const_assert!(f32::from_bits(MASKED_NAN1).is_nan());++    const_assert!(f32::from_bits(MASKED_NAN1).to_bits(), MASKED_NAN1);+    const_assert!(f32::from_bits(MASKED_NAN2).to_bits(), MASKED_NAN2);

Ah, yes. Sorry I forgot about this. By the way, this means that the result of to_bits may differ between runtime and compile-time on x86. I think this is fine as long as it remains nightly only, but we should be careful about accidentally stabilizing these before we're sure.

ecstatic-morse

comment created time in a month

pull request commentrust-lang/rust

Advertise correct stable version for const control flow

r? @oli-obk

ecstatic-morse

comment created time in a month

PR opened rust-lang/rust

Advertise correct stable version for const control flow

#72437 was opened before the 1.45 release but merged afterwards. These will be stable in 1.46.

+2 -2

0 comment

1 changed file

pr created time in a month

create barnchecstatic-morse/rust

branch : fix-stable-version

created branch time in a month

issue commentrust-lang/rustc-dev-guide

Make contributing.md into a series of tutorials

My impression of the guide/forge split is that the forge is specifically targeted at org members while the guide is targeted at everyone who wants to contribute. I envisioned that sections like "licensing" and "bors" would contain only the minimum amount of information needed by new contributors.

mark-i-m

comment created time in a month

pull request commentrust-lang/rust

Rollup of 6 pull requests

There's discussion in https://discord.com/channels/442252698964721669/629052535449190400/722335918408597515. All these PRs are either rollup=always or could have easily been marked rollup=always. All of them are tiny fixes except for the stabilization PR, which only needs to land before the beta branch. Point taken about the current size of the queue, but I don't think it's a good habit to be putting 20 line rollups at the front of the line.

Dylan-DPC

comment created time in a month

pull request commentrust-lang/rust

Some refactoring around intrinsic type checking

@bors rollup

oli-obk

comment created time in a month

pull request commentrust-lang/rust

Rollup of 6 pull requests

@Manishearth I was encouraged by your efforts to move us away from small rollups with only trivial PRs. However, this rollup represents a return to the status quo. Is there a better way to enforce the rules for rollups?

Dylan-DPC

comment created time in a month

pull request commentrust-lang/rust

Rewrite the `Visitor` for `non_ssa_locals`

r? @eddyb

ecstatic-morse

comment created time in a month

more