Skip to content

Commit

Permalink
Clarify reason for disabled lint
Browse files Browse the repository at this point in the history
  • Loading branch information
senekor committed Jul 18, 2023
1 parent dd0ea4e commit 1a43b4b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions exercises/practice/binary-search/tests/binary-search.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// 1.65.0 says these &[] borrows are needless borrows,
// but 1.64.0 requires them.
// The Rust track will reevaluate this after 1.65.0 is released.
// The &[] borrows are required for the base exercise,
// where `find` is not generic. Once `find` is made generic,
// the borrows become needless. Since we want the tests to work
// without clippy warnings for both people who take on the
// additional challenge and people who don't, we disable this lint.
#![allow(clippy::needless_borrow)]

use binary_search::find;
Expand Down

0 comments on commit 1a43b4b

Please sign in to comment.