Skip to content

Commit

Permalink
Fix tests for latest toolchain
Browse files Browse the repository at this point in the history
  • Loading branch information
udoprog committed May 18, 2024
1 parent db4e180 commit 53f13cc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.68.2
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- run: cargo clippy --workspace --all-features --all-targets -- -D warnings
Expand Down
4 changes: 2 additions & 2 deletions crates/borrowme/tests/ui/trait_diagnostics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ pub struct Word<'a> {
lang: &'a MyType,
}

fn to_owned_my_type(this: &MyType) -> MyOwnedType {
fn to_owned_my_type(_: &MyType) -> MyOwnedType {
MyOwnedType
}

fn borrow_my_type(this: &MyOwnedType) -> &MyType {
fn borrow_my_type(_: &MyOwnedType) -> &MyType {
&MyType
}

Expand Down
4 changes: 2 additions & 2 deletions crates/borrowme/tests/ui/trait_diagnostics.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ error[E0277]: `MyType` doesn't implement `Debug`
13 | lang: &'a MyType,
| ^^^^^^^^^^^^^^^^ `MyType` cannot be formatted using `{:?}`
|
= help: the trait `Debug` is not implemented for `MyType`
= help: the trait `Debug` is not implemented for `MyType`, which is required by `&&'a MyType: Debug`
= note: add `#[derive(Debug)]` to `MyType` or manually `impl Debug for MyType`
= note: this error originates in the derive macro `Debug` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider annotating `MyType` with `#[derive(Debug)]`
Expand Down Expand Up @@ -41,7 +41,7 @@ error[E0277]: `MyOwnedType` doesn't implement `Debug`
13 | lang: &'a MyType,
| ^^^^^^^ `MyOwnedType` cannot be formatted using `{:?}`
|
= help: the trait `Debug` is not implemented for `MyOwnedType`
= help: the trait `Debug` is not implemented for `MyOwnedType`, which is required by `&MyOwnedType: Debug`
= note: add `#[derive(Debug)]` to `MyOwnedType` or manually `impl Debug for MyOwnedType`
= note: this error originates in the derive macro `Debug` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider annotating `MyOwnedType` with `#[derive(Debug)]`
Expand Down

0 comments on commit 53f13cc

Please sign in to comment.