diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2012-08-20 16:53:33 -0700 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2012-08-21 10:28:34 -0700 |
| commit | 652b312122139501ae513e9c985d9c31030684b3 (patch) | |
| tree | a7c58b1ff1aa6d13e9b66b57cad50495f1657e51 /src/libstd | |
| parent | 8ee79c79aada1b5943b5ada11570f9b903c74579 (diff) | |
| download | rust-652b312122139501ae513e9c985d9c31030684b3.tar.gz rust-652b312122139501ae513e9c985d9c31030684b3.zip | |
more sound treatment of fn& regions; change all & to be distinct
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/arc.rs | 2 | ||||
| -rw-r--r-- | src/libstd/sync.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/arc.rs b/src/libstd/arc.rs index 355567e07e2..811c157498d 100644 --- a/src/libstd/arc.rs +++ b/src/libstd/arc.rs @@ -361,7 +361,7 @@ impl<T: const send> &rw_arc<T> { } /// To be called inside of the write_downgrade block. - fn downgrade(+token: rw_write_mode<T>) -> rw_read_mode<T> { + fn downgrade(+token: rw_write_mode/&a<T>) -> rw_read_mode/&a<T> { // The rwlock should assert that the token belongs to us for us. let state = unsafe { get_shared_immutable_state(&self.x) }; let rw_write_mode((data, t, _poison)) = token; diff --git a/src/libstd/sync.rs b/src/libstd/sync.rs index 1438e4ab180..bd0e815d325 100644 --- a/src/libstd/sync.rs +++ b/src/libstd/sync.rs @@ -538,7 +538,7 @@ impl &rwlock { } /// To be called inside of the write_downgrade block. - fn downgrade(+token: rwlock_write_mode) -> rwlock_read_mode { + fn downgrade(+token: rwlock_write_mode/&a) -> rwlock_read_mode/&a { if !ptr::ref_eq(self, token.lock) { fail ~"Can't downgrade() with a different rwlock's write_mode!"; } |
