diff options
| author | Trevor Gross <tmgross@umich.edu> | 2023-02-06 15:01:40 -0500 |
|---|---|---|
| committer | Trevor Gross <tmgross@umich.edu> | 2023-02-10 20:46:14 -0500 |
| commit | 787b1116e80bfa6138227212814990aa4eccf186 (patch) | |
| tree | f1320ee316737ef65b538b452a5af9aa2ec2a3a6 /library/std/src/sys_common | |
| parent | 5a8dfd933a70cc47e44502a20fd67dfaec6555d5 (diff) | |
| download | rust-787b1116e80bfa6138227212814990aa4eccf186.tar.gz rust-787b1116e80bfa6138227212814990aa4eccf186.zip | |
Rename atomic 'as_mut_ptr' to 'as_ptr' to match Cell (ref #66893)
Diffstat (limited to 'library/std/src/sys_common')
| -rw-r--r-- | library/std/src/sys_common/thread_parking/id.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/library/std/src/sys_common/thread_parking/id.rs b/library/std/src/sys_common/thread_parking/id.rs index e98169597c3..575988ec760 100644 --- a/library/std/src/sys_common/thread_parking/id.rs +++ b/library/std/src/sys_common/thread_parking/id.rs @@ -60,7 +60,7 @@ impl Parker { if state == PARKED { // Loop to guard against spurious wakeups. while state == PARKED { - park(self.state.as_mut_ptr().addr()); + park(self.state.as_ptr().addr()); state = self.state.load(Acquire); } @@ -76,7 +76,7 @@ impl Parker { let state = self.state.fetch_sub(1, Acquire).wrapping_sub(1); if state == PARKED { - park_timeout(dur, self.state.as_mut_ptr().addr()); + park_timeout(dur, self.state.as_ptr().addr()); // Swap to ensure that we observe all state changes with acquire // ordering, even if the state has been changed after the timeout // occured. @@ -99,7 +99,7 @@ impl Parker { // and terminated before this call is made. This call then returns an // error or wakes up an unrelated thread. The platform API and // environment does allow this, however. - unpark(tid, self.state.as_mut_ptr().addr()); + unpark(tid, self.state.as_ptr().addr()); } } } |
