Skip to content

Commit bdbe6e2

Browse files
authored
Rollup merge of rust-lang#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.
2 parents 04eb88c + 0741645 commit bdbe6e2

File tree

2 files changed

+0
-5
lines changed

2 files changed

+0
-5
lines changed

src/libcore/str/mod.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1399,9 +1399,6 @@ Section: Comparing strings
13991399
*/
14001400

14011401
/// Bytewise slice equality
1402-
/// NOTE: This function is (ab)used in rustc::middle::trans::_match
1403-
/// to compare &[u8] byte slices that are not necessarily valid UTF-8.
1404-
#[lang = "str_eq"]
14051402
#[inline]
14061403
fn eq_slice(a: &str, b: &str) -> bool {
14071404
a.as_bytes() == b.as_bytes()

src/librustc/middle/lang_items.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,8 +280,6 @@ language_item_table! {
280280
EqTraitLangItem, "eq", eq_trait;
281281
OrdTraitLangItem, "ord", ord_trait;
282282

283-
StrEqFnLangItem, "str_eq", str_eq_fn;
284-
285283
// A number of panic-related lang items. The `panic` item corresponds to
286284
// divide-by-zero and various panic cases with `match`. The
287285
// `panic_bounds_check` item is for indexing arrays.

0 commit comments

Comments
 (0)