Skip to content

Commit

Permalink
Move iterator internals to underscore const
Browse files Browse the repository at this point in the history
The `const _` language feature did not exist yet when this code was
written.
  • Loading branch information
dtolnay committed Dec 21, 2023
1 parent c880060 commit cbc57de
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ mod private {
#[doc(hidden)]
pub use crate::private::*;

const ITER: () = {
const _: () = {
fn into_iter<T: Collect>() -> Iter<T> {
let head = T::registry().head.load(Ordering::Acquire);
Iter {
Expand Down Expand Up @@ -473,8 +473,3 @@ macro_rules! __do_submit {
}
};
}

#[allow(dead_code)]
fn unused() {
let () = ITER;
}

0 comments on commit cbc57de

Please sign in to comment.