Skip to content

Commit 9542bef

Browse files
committed
Bump edition to 2024
1 parent 3117105 commit 9542bef

File tree

4 files changed

+9
-7
lines changed

4 files changed

+9
-7
lines changed

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
name = "cs431"
33
version = "0.1.0"
44
authors = ["Jeehoon Kang <[email protected]>"]
5-
edition = "2021"
5+
edition = "2024"
66

77
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
88

99
[dependencies]
1010
crossbeam-epoch = "0.9.18"
11-
crossbeam-utils = "0.8.19"
11+
crossbeam-utils = "0.8.21"

rust-toolchain

Lines changed: 0 additions & 1 deletion
This file was deleted.

rust-toolchain.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[toolchain]
2+
channel = "1.85.0"
3+
components = ["rustfmt", "clippy", "rust-analyzer"]

src/lockfree/list.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ pub struct List<K, V> {
2727
head: Atomic<Node<K, V>>,
2828
}
2929

30-
// Unlike stack and queue, we need `K` and `V` to be `Sync` for the list to be `Sync`,
31-
// as both `K` and `V` are accessed concurrently in `find` and `delete`, respectively.
30+
// Unlike stack and queue, we need `K` and `V` to be `Sync` for the list to be `Sync`, as both `K`
31+
// and `V` are accessed concurrently in `find` and `delete`, respectively.
3232
unsafe impl<K: Sync, V: Sync> Sync for List<K, V> {}
3333
unsafe impl<K: Send, V: Send> Send for List<K, V> {}
3434

@@ -155,8 +155,8 @@ where
155155
while node.with_tag(0) != self.curr {
156156
// SAFETY: All nodes in the unlinked chain are not null.
157157
//
158-
// NOTE: It may seem like this load could be non-atomic, but that would
159-
// race with the `fetch_or` done in `remove`.
158+
// NOTE: It may seem like this load could be non-atomic, but that would race with the
159+
// `fetch_or` done in `remove`.
160160
let next = unsafe { node.deref() }.next.load(Relaxed, guard);
161161

162162
// SAFETY: we unlinked the chain with above CAS.

0 commit comments

Comments
 (0)