Skip to content

Commit b5adb81

Browse files
committed
---
yaml --- r: 235990 b: refs/heads/stable c: ddbce11 h: refs/heads/master v: v3
1 parent ab92bf3 commit b5adb81

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: afae2ff723393b3ab4ccffef6ac7c6d1809e2da0
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: f859507de8c410b648d934d8f5ec1c52daac971d
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 5944303339fac6f2aa100ae4d2ac5fb72814c4e2
32+
refs/heads/stable: ddbce1107bc95ea4ad0da6299ca31e313a39e0fc
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/src/libcollections/str.rs

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,6 +425,7 @@ impl str {
425425
since = "1.0.0")]
426426
#[unstable(feature = "unicode",
427427
reason = "this functionality may only be provided by libunicode")]
428+
#[inline]
428429
pub fn width(&self, is_cjk: bool) -> usize {
429430
UnicodeStr::width(self, is_cjk)
430431
}
@@ -460,6 +461,7 @@ impl str {
460461
with the existence of the char_indices iterator or \
461462
this method may want to be replaced with checked \
462463
slicing")]
464+
#[inline]
463465
pub fn is_char_boundary(&self, index: usize) -> bool {
464466
core_str::StrExt::is_char_boundary(self, index)
465467
}
@@ -515,6 +517,7 @@ impl str {
515517
/// }
516518
/// ```
517519
#[stable(feature = "rust1", since = "1.0.0")]
520+
#[inline]
518521
pub unsafe fn slice_unchecked(&self, begin: usize, end: usize) -> &str {
519522
core_str::StrExt::slice_unchecked(self, begin, end)
520523
}
@@ -523,6 +526,7 @@ impl str {
523526
///
524527
/// Same as `slice_unchecked`, but works with `&mut str` instead of `&str`.
525528
#[unstable(feature = "str_slice_mut", reason = "recently added")]
529+
#[inline]
526530
pub unsafe fn slice_mut_unchecked(&mut self, begin: usize, end: usize) -> &mut str {
527531
core_str::StrExt::slice_mut_unchecked(self, begin, end)
528532
}
@@ -558,6 +562,7 @@ impl str {
558562
#[deprecated(since = "1.3.0",
559563
reason = "can be implemented with char_indices and \
560564
hasn't seen enough use to justify inclusion")]
565+
#[inline]
561566
pub fn slice_chars(&self, begin: usize, end: usize) -> &str {
562567
core_str::StrExt::slice_chars(self, begin, end)
563568
}
@@ -611,6 +616,7 @@ impl str {
611616
reason = "often replaced by char_indices, this method may \
612617
be removed in favor of just char_at() or eventually \
613618
removed altogether")]
619+
#[inline]
614620
pub fn char_range_at(&self, start: usize) -> CharRange {
615621
core_str::StrExt::char_range_at(self, start)
616622
}
@@ -669,6 +675,7 @@ impl str {
669675
reason = "often replaced by char_indices, this method may \
670676
be removed in favor of just char_at_reverse() or \
671677
eventually removed altogether")]
678+
#[inline]
672679
pub fn char_range_at_reverse(&self, start: usize) -> CharRange {
673680
core_str::StrExt::char_range_at_reverse(self, start)
674681
}
@@ -696,6 +703,7 @@ impl str {
696703
future; it is normally replaced by chars/char_indices \
697704
iterators or by getting the first char from a \
698705
subslice")]
706+
#[inline]
699707
pub fn char_at(&self, i: usize) -> char {
700708
core_str::StrExt::char_at(self, i)
701709
}
@@ -722,6 +730,7 @@ impl str {
722730
reason = "see char_at for more details, but reverse semantics \
723731
are also somewhat unclear, especially with which \
724732
cases generate panics")]
733+
#[inline]
725734
pub fn char_at_reverse(&self, i: usize) -> char {
726735
core_str::StrExt::char_at_reverse(self, i)
727736
}
@@ -756,6 +765,7 @@ impl str {
756765
reason = "awaiting conventions about shifting and slices and \
757766
may not be warranted with the existence of the chars \
758767
and/or char_indices iterators")]
768+
#[inline]
759769
pub fn slice_shift_char(&self) -> Option<(char, &str)> {
760770
core_str::StrExt::slice_shift_char(self)
761771
}
@@ -818,6 +828,7 @@ impl str {
818828
/// '\u{1f1e8}', '\u{1f1ed}', ' ', '한']);
819829
/// ```
820830
#[stable(feature = "rust1", since = "1.0.0")]
831+
#[inline]
821832
pub fn chars(&self) -> Chars {
822833
core_str::StrExt::chars(self)
823834
}
@@ -833,6 +844,7 @@ impl str {
833844
/// assert_eq!(v, b);
834845
/// ```
835846
#[stable(feature = "rust1", since = "1.0.0")]
847+
#[inline]
836848
pub fn char_indices(&self) -> CharIndices {
837849
core_str::StrExt::char_indices(self)
838850
}
@@ -847,6 +859,7 @@ impl str {
847859
/// assert_eq!(v, b"bors".to_vec());
848860
/// ```
849861
#[stable(feature = "rust1", since = "1.0.0")]
862+
#[inline]
850863
pub fn bytes(&self) -> Bytes {
851864
core_str::StrExt::bytes(self)
852865
}
@@ -863,6 +876,7 @@ impl str {
863876
/// assert_eq!(v, ["Mary", "had", "a", "little", "lamb"]);
864877
/// ```
865878
#[stable(feature = "split_whitespace", since = "1.1.0")]
879+
#[inline]
866880
pub fn split_whitespace(&self) -> SplitWhitespace {
867881
UnicodeStr::split_whitespace(self)
868882
}
@@ -886,6 +900,7 @@ impl str {
886900
#[unstable(feature = "str_words",
887901
reason = "the precise algorithm to use is unclear")]
888902
#[allow(deprecated)]
903+
#[inline]
889904
pub fn words(&self) -> Words {
890905
UnicodeStr::words(self)
891906
}
@@ -912,6 +927,7 @@ impl str {
912927
/// assert_eq!(v, ["foo", "bar", "", "baz"]);
913928
/// ```
914929
#[stable(feature = "rust1", since = "1.0.0")]
930+
#[inline]
915931
pub fn lines(&self) -> Lines {
916932
core_str::StrExt::lines(self)
917933
}
@@ -939,6 +955,7 @@ impl str {
939955
/// assert_eq!(v, ["foo", "bar", "", "baz"]);
940956
/// ```
941957
#[stable(feature = "rust1", since = "1.0.0")]
958+
#[inline]
942959
pub fn lines_any(&self) -> LinesAny {
943960
core_str::StrExt::lines_any(self)
944961
}

0 commit comments

Comments
 (0)