Rollup merge of #44658 - leodasvacas:remove-str-eq-lang-item, r=arielb1

Remove str_eq lang item

It's not really a lang item. Also remove outdated note. The reference uses this as an example so it has to be updated.
This commit is contained in:
Corey Farwell
2017-09-23 00:29:11 -04:00
committed by GitHub
2 changed files with 0 additions and 5 deletions
-3
View File
@@ -1399,9 +1399,6 @@ impl<'a> FusedIterator for LinesAny<'a> {}
*/
/// Bytewise slice equality
/// NOTE: This function is (ab)used in rustc::middle::trans::_match
/// to compare &[u8] byte slices that are not necessarily valid UTF-8.
#[lang = "str_eq"]
#[inline]
fn eq_slice(a: &str, b: &str) -> bool {
a.as_bytes() == b.as_bytes()
-2
View File
@@ -280,8 +280,6 @@ pub fn collect<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>) -> LanguageItems {
EqTraitLangItem, "eq", eq_trait;
OrdTraitLangItem, "ord", ord_trait;
StrEqFnLangItem, "str_eq", str_eq_fn;
// A number of panic-related lang items. The `panic` item corresponds to
// divide-by-zero and various panic cases with `match`. The
// `panic_bounds_check` item is for indexing arrays.