mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-26 00:34:06 +00:00
std: fix the non-stage0 str::raw::slice_bytes which broke in a merge
This commit is contained in:
parent
6fcf2ee8e3
commit
e48ca19bc5
@ -1051,7 +1051,7 @@ pub mod raw {
|
||||
/// If end is greater than the length of the string.
|
||||
#[cfg(not(stage0))]
|
||||
#[inline]
|
||||
pub unsafe fn slice_bytes(s: &str, begin: uint, end: uint) -> &str {
|
||||
pub unsafe fn slice_bytes<'a>(s: &'a str, begin: uint, end: uint) -> &'a str {
|
||||
do s.as_imm_buf |sbuf, n| {
|
||||
assert!((begin <= end));
|
||||
assert!((end <= n));
|
||||
|
Loading…
Reference in New Issue
Block a user