Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace "cfg(test)" with "cfg(doctest)" for readme testing #761

Merged
merged 1 commit into from
May 9, 2020

Conversation

GuillaumeGomez
Copy link
Contributor

Rustdoc now passes "doctest" when running in test mode.

@cuviper
Copy link
Member

cuviper commented May 9, 2020

Thanks!

bors r+

@bors bors bot merged commit c71a235 into rayon-rs:master May 9, 2020
@GuillaumeGomez GuillaumeGomez deleted the patch-1 branch May 9, 2020 09:11
src/lib.rs Show resolved Hide resolved
bors bot added a commit to taiki-e/cargo-hack that referenced this pull request Dec 5, 2020
102: Add --version-range option r=taiki-e a=taiki-e

Closes #93
> This may be useful for catching issues like BurntSushi/termcolor#35, rust-lang/regex#685, rayon-rs/rayon#761 (comment), rust-lang/rust-clippy#6324.

```text
--version-range <START>..[END]
    Perform commands on a specified (inclusive) range of Rust versions.

    If the given range is unclosed, the latest stable compiler is treated as the upper bound.

    Note that ranges are always inclusive ranges.

--version-step <NUM>
    Specify the version interval of --version-range.
```


Note: Ranges are always **inclusive** ranges. (`start..=end`)

```console
$ cargo hack check --version-range 1.46..1.47
info: running `cargo +1.46 check` on cargo-hack (1/2)
    Finished dev [unoptimized + debuginfo] target(s) in 0.28s
info: running `cargo +1.47 check` on cargo-hack (2/2)
    Finished dev [unoptimized + debuginfo] target(s) in 0.23s
```

If the given range is unclosed, the latest stable compiler is treated as the upper bound.

```console
$ cargo hack check --version-range 1.46..
info: running `cargo +1.46 check` on cargo-hack (1/3)
    Finished dev [unoptimized + debuginfo] target(s) in 0.28s
info: running `cargo +1.47 check` on cargo-hack (2/3)
    Finished dev [unoptimized + debuginfo] target(s) in 0.23s
info: running `cargo +1.48 check` on cargo-hack (3/3)
    Finished dev [unoptimized + debuginfo] target(s) in 0.28
```

You can also specify the version interval by using `--version-step`. (`(start..=end).step_by(step)`)

```console
$ cargo hack check --version-range 1.45.. --version-step 2
info: running `cargo +1.45 check` on cargo-hack (1/2)
    Finished dev [unoptimized + debuginfo] target(s) in 0.29s
info: running `cargo +1.47 check` on cargo-hack (2/2)
    Finished dev [unoptimized + debuginfo] target(s) in 0.25s
```

Co-authored-by: Taiki Endo <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants