Skip to content

Commit 52db0ce

Browse files
author
The Miri Cronjob Bot
committed
Merge from rustc
2 parents 5946616 + fd2eb39 commit 52db0ce

File tree

226 files changed

+3059
-3117
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

226 files changed

+3059
-3117
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,11 @@ jobs:
182182
- name: install MinGW
183183
run: src/ci/scripts/install-mingw.sh
184184

185+
# Workaround for spurious ci failures after mingw install
186+
# see https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/Spurious.20bors.20CI.20failures/near/528915775
187+
- name: ensure home dir exists
188+
run: mkdir -p ~
189+
185190
- name: install ninja
186191
run: src/ci/scripts/install-ninja.sh
187192

Cargo.lock

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5069,14 +5069,6 @@ dependencies = [
50695069
"syn 1.0.109",
50705070
]
50715071

5072-
[[package]]
5073-
name = "suggest-tests"
5074-
version = "0.1.0"
5075-
dependencies = [
5076-
"build_helper",
5077-
"glob",
5078-
]
5079-
50805072
[[package]]
50815073
name = "syn"
50825074
version = "1.0.109"

Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ members = [
3939
"src/tools/rustdoc-gui-test",
4040
"src/tools/rustdoc-themes",
4141
"src/tools/rustfmt",
42-
"src/tools/suggest-tests",
4342
"src/tools/test-float-parse",
4443
"src/tools/tidy",
4544
"src/tools/tier-check",

compiler/rustc_ast/src/expand/mod.rs

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,7 @@
11
//! Definitions shared by macros / syntax extensions and e.g. `rustc_middle`.
22
33
use rustc_macros::{Decodable, Encodable, HashStable_Generic};
4-
use rustc_span::Ident;
5-
use rustc_span::def_id::DefId;
6-
7-
use crate::MetaItem;
84

95
pub mod allocator;
106
pub mod autodiff_attrs;
117
pub mod typetree;
12-
13-
#[derive(Debug, Clone, Encodable, Decodable, HashStable_Generic)]
14-
pub struct StrippedCfgItem<ModId = DefId> {
15-
pub parent_module: ModId,
16-
pub ident: Ident,
17-
pub cfg: MetaItem,
18-
}
19-
20-
impl<ModId> StrippedCfgItem<ModId> {
21-
pub fn map_mod_id<New>(self, f: impl FnOnce(ModId) -> New) -> StrippedCfgItem<New> {
22-
StrippedCfgItem { parent_module: f(self.parent_module), ident: self.ident, cfg: self.cfg }
23-
}
24-
}

compiler/rustc_ast_lowering/src/lib.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ use std::sync::Arc;
4242

4343
use rustc_ast::node_id::NodeMap;
4444
use rustc_ast::{self as ast, *};
45-
use rustc_attr_parsing::{AttributeParser, OmitDoc};
45+
use rustc_attr_parsing::{AttributeParser, Late, OmitDoc};
4646
use rustc_data_structures::fingerprint::Fingerprint;
4747
use rustc_data_structures::sorted_map::SortedMap;
4848
use rustc_data_structures::stable_hasher::{HashStable, StableHasher};
@@ -192,7 +192,12 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
192192
// interact with `gen`/`async gen` blocks
193193
allow_async_iterator: [sym::gen_future, sym::async_iterator].into(),
194194

195-
attribute_parser: AttributeParser::new(tcx.sess, tcx.features(), registered_tools),
195+
attribute_parser: AttributeParser::new(
196+
tcx.sess,
197+
tcx.features(),
198+
registered_tools,
199+
Late,
200+
),
196201
delayed_lints: Vec::new(),
197202
}
198203
}

compiler/rustc_attr_data_structures/src/attributes.rs

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use rustc_ast::token::CommentKind;
33
use rustc_ast::{self as ast, AttrStyle};
44
use rustc_macros::{Decodable, Encodable, HashStable_Generic, PrintAttribute};
55
use rustc_span::hygiene::Transparency;
6-
use rustc_span::{Span, Symbol};
6+
use rustc_span::{Ident, Span, Symbol};
77
use thin_vec::ThinVec;
88

99
use crate::{DefaultBodyStability, PartialConstStability, PrintAttribute, RustcVersion, Stability};
@@ -69,6 +69,7 @@ pub enum ReprAttr {
6969
ReprAlign(Align),
7070
}
7171
pub use ReprAttr::*;
72+
use rustc_span::def_id::DefId;
7273

7374
pub enum TransparencyError {
7475
UnknownTransparency(Symbol, Span),
@@ -140,6 +141,30 @@ pub enum UsedBy {
140141
Linker,
141142
}
142143

144+
#[derive(Debug, Clone, Encodable, Decodable, HashStable_Generic)]
145+
pub struct StrippedCfgItem<ModId = DefId> {
146+
pub parent_module: ModId,
147+
pub ident: Ident,
148+
pub cfg: (CfgEntry, Span),
149+
}
150+
151+
impl<ModId> StrippedCfgItem<ModId> {
152+
pub fn map_mod_id<New>(self, f: impl FnOnce(ModId) -> New) -> StrippedCfgItem<New> {
153+
StrippedCfgItem { parent_module: f(self.parent_module), ident: self.ident, cfg: self.cfg }
154+
}
155+
}
156+
157+
#[derive(Encodable, Decodable, Clone, Debug, PartialEq, Eq, Hash)]
158+
#[derive(HashStable_Generic, PrintAttribute)]
159+
pub enum CfgEntry {
160+
All(ThinVec<CfgEntry>, Span),
161+
Any(ThinVec<CfgEntry>, Span),
162+
Not(Box<CfgEntry>, Span),
163+
Bool(bool, Span),
164+
NameValue { name: Symbol, name_span: Span, value: Option<(Symbol, Span)>, span: Span },
165+
Version(Option<RustcVersion>, Span),
166+
}
167+
143168
/// Represents parsed *built-in* inert attributes.
144169
///
145170
/// ## Overview
@@ -349,6 +374,9 @@ pub enum AttributeKind {
349374
/// Represents `#[path]`
350375
Path(Symbol, Span),
351376

377+
/// Represents `#[pointee]`
378+
Pointee(Span),
379+
352380
/// Represents `#[rustc_pub_transparent]` (used by the `repr_transparent_external_private_fields` lint).
353381
PubTransparent(Span),
354382

compiler/rustc_attr_data_structures/src/encode_cross_crate.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ impl AttributeKind {
5757
ParenSugar(..) => No,
5858
PassByValue(..) => Yes,
5959
Path(..) => No,
60+
Pointee(..) => No,
6061
PubTransparent(..) => Yes,
6162
Repr { .. } => No,
6263
RustcLayoutScalarValidRangeEnd(..) => Yes,

0 commit comments

Comments
 (0)