Skip to content

Commit 759a5d1

Browse files
committed
Fix up Split docs
Because these structures are created by a macro, the doc comments don't quite work: the leading /// isn't stripped. Instead, just use #[doc] so that they render correctly.
1 parent 750f2c6 commit 759a5d1

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

src/libcore/str/mod.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -635,10 +635,10 @@ impl<'a, P: Pattern<'a>> SplitInternal<'a, P> {
635635

636636
generate_pattern_iterators! {
637637
forward:
638-
/// Created with the method `.split()`.
638+
#[doc="Created with the method `.split()`."]
639639
struct Split;
640640
reverse:
641-
/// Created with the method `.rsplit()`.
641+
#[doc="Created with the method `.rsplit()`."]
642642
struct RSplit;
643643
stability:
644644
#[stable(feature = "rust1", since = "1.0.0")]
@@ -649,10 +649,10 @@ generate_pattern_iterators! {
649649

650650
generate_pattern_iterators! {
651651
forward:
652-
/// Created with the method `.split_terminator()`.
652+
#[doc="Created with the method `.split_terminator()`."]
653653
struct SplitTerminator;
654654
reverse:
655-
/// Created with the method `.rsplit_terminator()`.
655+
#[doc="Created with the method `.rsplit_terminator()`."]
656656
struct RSplitTerminator;
657657
stability:
658658
#[stable(feature = "rust1", since = "1.0.0")]
@@ -695,10 +695,10 @@ impl<'a, P: Pattern<'a>> SplitNInternal<'a, P> {
695695

696696
generate_pattern_iterators! {
697697
forward:
698-
/// Created with the method `.splitn()`.
698+
#[doc="Created with the method `.splitn()`."]
699699
struct SplitN;
700700
reverse:
701-
/// Created with the method `.rsplitn()`.
701+
#[doc="Created with the method `.rsplitn()`."]
702702
struct RSplitN;
703703
stability:
704704
#[stable(feature = "rust1", since = "1.0.0")]
@@ -729,10 +729,10 @@ impl<'a, P: Pattern<'a>> MatchIndicesInternal<'a, P> {
729729

730730
generate_pattern_iterators! {
731731
forward:
732-
/// Created with the method `.match_indices()`.
732+
#[doc="Created with the method `.match_indices()`."]
733733
struct MatchIndices;
734734
reverse:
735-
/// Created with the method `.rmatch_indices()`.
735+
#[doc="Created with the method `.rmatch_indices()`."]
736736
struct RMatchIndices;
737737
stability:
738738
#[unstable(feature = "core",
@@ -770,10 +770,10 @@ impl<'a, P: Pattern<'a>> MatchesInternal<'a, P> {
770770

771771
generate_pattern_iterators! {
772772
forward:
773-
/// Created with the method `.matches()`.
773+
#[doc="Created with the method `.matches()`."]
774774
struct Matches;
775775
reverse:
776-
/// Created with the method `.rmatches()`.
776+
#[doc="Created with the method `.rmatches()`."]
777777
struct RMatches;
778778
stability:
779779
#[unstable(feature = "core", reason = "type got recently added")]

0 commit comments

Comments
 (0)