about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlona Enraght-Moony <code@alona.page>2023-11-07 16:40:32 +0000
committerAlona Enraght-Moony <code@alona.page>2023-11-07 16:40:32 +0000
commit0875f456f1081929db5aabf67ee7713dd77cd303 (patch)
tree58e909d557520a557453c30efcee1c82af949421
parentf784fa7bd980916c235f5bd9bdbcf9389ea261f4 (diff)
downloadrust-0875f456f1081929db5aabf67ee7713dd77cd303.tar.gz
rust-0875f456f1081929db5aabf67ee7713dd77cd303.zip
tests/rustdoc-json: Remove more needless uses of `#![no_core]`.
These were'nt done with regex, but don't require changes to assertions.
-rw-r--r--tests/rustdoc-json/enums/field_hidden.rs6
-rw-r--r--tests/rustdoc-json/enums/kind.rs6
-rw-r--r--tests/rustdoc-json/enums/tuple_fields_hidden.rs6
-rw-r--r--tests/rustdoc-json/generic-associated-types/gats.rs9
-rw-r--r--tests/rustdoc-json/non_lifetime_binders.rs11
-rw-r--r--tests/rustdoc-json/traits/supertrait.rs2
6 files changed, 1 insertions, 39 deletions
diff --git a/tests/rustdoc-json/enums/field_hidden.rs b/tests/rustdoc-json/enums/field_hidden.rs
index f2409858057..74d96248d5c 100644
--- a/tests/rustdoc-json/enums/field_hidden.rs
+++ b/tests/rustdoc-json/enums/field_hidden.rs
@@ -1,11 +1,5 @@
 // Regression test for <https://github.com/rust-lang/rust/issues/100529>.
 
-#![no_core]
-#![feature(no_core, lang_items)]
-
-#[lang = "sized"]
-trait Sized {}
-
 // @has "$.index[*][?(@.name=='ParseError')]"
 // @has "$.index[*][?(@.name=='UnexpectedEndTag')]"
 // @is "$.index[*][?(@.name=='UnexpectedEndTag')].inner.variant.kind.tuple" [null]
diff --git a/tests/rustdoc-json/enums/kind.rs b/tests/rustdoc-json/enums/kind.rs
index 777161c4e4b..68483683464 100644
--- a/tests/rustdoc-json/enums/kind.rs
+++ b/tests/rustdoc-json/enums/kind.rs
@@ -1,11 +1,5 @@
 // ignore-tidy-linelength
 
-#![feature(no_core, lang_items)]
-#![no_core]
-
-#[lang = "sized"]
-trait Sized {}
-
 pub enum Foo {
     // @set Unit = "$.index[*][?(@.name=='Unit')].id"
     // @is "$.index[*][?(@.name=='Unit')].inner.variant.kind" '"plain"'
diff --git a/tests/rustdoc-json/enums/tuple_fields_hidden.rs b/tests/rustdoc-json/enums/tuple_fields_hidden.rs
index 34a4f4aec53..53cdf83ffa6 100644
--- a/tests/rustdoc-json/enums/tuple_fields_hidden.rs
+++ b/tests/rustdoc-json/enums/tuple_fields_hidden.rs
@@ -1,9 +1,3 @@
-#![feature(no_core, lang_items)]
-#![no_core]
-
-#[lang = "sized"]
-trait Sized {}
-
 // @set 1.1.0 = "$.index[*][?(@.docs=='1.1.0')].id"
 // @set 2.1.0 = "$.index[*][?(@.docs=='2.1.0')].id"
 // @set 2.1.1 = "$.index[*][?(@.docs=='2.1.1')].id"
diff --git a/tests/rustdoc-json/generic-associated-types/gats.rs b/tests/rustdoc-json/generic-associated-types/gats.rs
index 9cfe649243f..56d6e7a49db 100644
--- a/tests/rustdoc-json/generic-associated-types/gats.rs
+++ b/tests/rustdoc-json/generic-associated-types/gats.rs
@@ -1,14 +1,5 @@
 // ignore-tidy-linelength
 
-#![no_core]
-#![feature(lang_items, no_core, arbitrary_self_types)]
-
-#[lang = "sized"]
-pub trait Sized {}
-
-#[lang = "receiver"]
-pub trait Receiver {}
-
 pub trait Display {}
 
 pub trait LendingIterator {
diff --git a/tests/rustdoc-json/non_lifetime_binders.rs b/tests/rustdoc-json/non_lifetime_binders.rs
index cabee0b1caa..d925fcd5221 100644
--- a/tests/rustdoc-json/non_lifetime_binders.rs
+++ b/tests/rustdoc-json/non_lifetime_binders.rs
@@ -3,18 +3,9 @@
 #![feature(non_lifetime_binders)]
 #![allow(incomplete_features)]
 
-#![no_core]
-#![feature(lang_items, no_core)]
-
-#[lang = "sized"]
-pub trait Sized {}
-
 pub trait Trait {}
 
-#[lang = "phantom_data"]
-struct PhantomData<T_>;
-
-pub struct Wrapper<T_>(PhantomData<T_>);
+pub struct Wrapper<T_>(std::marker::PhantomData<T_>);
 
 // @count "$.index[*][?(@.name=='foo')].inner.function.generics.where_predicates[0].bound_predicate.generic_params[*]" 2
 // @is "$.index[*][?(@.name=='foo')].inner.function.generics.where_predicates[0].bound_predicate.generic_params[0].name" \"\'a\"
diff --git a/tests/rustdoc-json/traits/supertrait.rs b/tests/rustdoc-json/traits/supertrait.rs
index 6504467291d..bbae3557cf9 100644
--- a/tests/rustdoc-json/traits/supertrait.rs
+++ b/tests/rustdoc-json/traits/supertrait.rs
@@ -1,7 +1,5 @@
 // ignore-tidy-linelength
 
-#![feature(lang_items)]
-
 // @set loud_id = "$.index[*][?(@.name=='Loud')].id"
 pub trait Loud {}