File tree Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -1405,16 +1405,6 @@ impl<'a> DoubleEndedIterator for LinesAny<'a> {
14051405#[ allow( deprecated) ]
14061406impl < ' a > FusedIterator for LinesAny < ' a > { }
14071407
1408- /*
1409- Section: Comparing strings
1410- */
1411-
1412- /// Bytewise slice equality
1413- #[ inline]
1414- fn eq_slice ( a : & str , b : & str ) -> bool {
1415- a. as_bytes ( ) == b. as_bytes ( )
1416- }
1417-
14181408/*
14191409Section: UTF-8 validation
14201410*/
@@ -1590,7 +1580,6 @@ mod traits {
15901580 use cmp:: Ordering ;
15911581 use ops;
15921582 use slice:: { self , SliceIndex } ;
1593- use str:: eq_slice;
15941583
15951584 /// Implements ordering of strings.
15961585 ///
@@ -1611,7 +1600,7 @@ mod traits {
16111600 impl PartialEq for str {
16121601 #[ inline]
16131602 fn eq ( & self , other : & str ) -> bool {
1614- eq_slice ( self , other)
1603+ self . as_bytes ( ) == other. as_bytes ( )
16151604 }
16161605 #[ inline]
16171606 fn ne ( & self , other : & str ) -> bool { !( * self ) . eq ( other) }
You can’t perform that action at this time.
0 commit comments