diff options
| author | bors <bors@rust-lang.org> | 2014-07-04 19:01:33 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-07-04 19:01:33 +0000 |
| commit | 935da0739e71c5581e5e6abb564e18f894e0ec04 (patch) | |
| tree | febd32b41fc7a597d749fbd231f54b7137bed9a1 /src/libstd | |
| parent | 25e8b6ed9c9cf60448eb95a0e8a42330ed44f479 (diff) | |
| parent | 29ec2506abb1d382e432cae2519aa7b7695c276a (diff) | |
| download | rust-935da0739e71c5581e5e6abb564e18f894e0ec04.tar.gz rust-935da0739e71c5581e5e6abb564e18f894e0ec04.zip | |
auto merge of #15405 : pcwalton/rust/delifetime, r=nick29581
This was parsed by the parser but completely ignored; not even stored in
the AST!
This breaks code that looks like:
static X: &'static [u8] = &'static [1, 2, 3];
Change this code to the shorter:
static X: &'static [u8] = &[1, 2, 3];
Closes #15312.
[breaking-change]
r? @nick29581
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/collections/hashmap.rs | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/libstd/collections/hashmap.rs b/src/libstd/collections/hashmap.rs index 7c01a0342ed..098e87243b6 100644 --- a/src/libstd/collections/hashmap.rs +++ b/src/libstd/collections/hashmap.rs @@ -294,8 +294,7 @@ mod table { unsafe { debug_assert!(*self.hashes.offset(idx) != EMPTY_BUCKET); - (&'a *self.keys.offset(idx), - &'a *self.vals.offset(idx)) + (&*self.keys.offset(idx), &*self.vals.offset(idx)) } } @@ -306,8 +305,7 @@ mod table { unsafe { debug_assert!(*self.hashes.offset(idx) != EMPTY_BUCKET); - (&'a *self.keys.offset(idx), - &'a mut *self.vals.offset(idx)) + (&*self.keys.offset(idx), &mut *self.vals.offset(idx)) } } @@ -319,8 +317,7 @@ mod table { unsafe { debug_assert!(*self.hashes.offset(idx) != EMPTY_BUCKET); (transmute(self.hashes.offset(idx)), - &'a mut *self.keys.offset(idx), - &'a mut *self.vals.offset(idx)) + &mut *self.keys.offset(idx), &mut *self.vals.offset(idx)) } } |
