Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit b77e018

Browse files
committedMar 6, 2024
Auto merge of #122045 - matthiaskrgr:rollup-5l3vpn7, r=matthiaskrgr
Rollup of 9 pull requests Successful merges: - #121065 (Add basic i18n guidance for `Display`) - #121744 (Stop using Bubble in coherence and instead emulate it with an intercrate check) - #121829 (Dummy tweaks (attempt 2)) - #121857 (Implement async closure signature deduction) - #121894 (const_eval_select: make it safe but be careful with what we expose on stable for now) - #122014 (Change some attributes to only_local.) - #122016 (will_wake tests fail on Miri and that is expected) - #122018 (only set noalias on Box with the global allocator) - #122028 (Remove some dead code) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 62415e2 + 4f73d2a commit b77e018

File tree

44 files changed

+291
-133
lines changed

Some content is hidden

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

44 files changed

+291
-133
lines changed
 

‎compiler/rustc_abi/src/lib.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1612,8 +1612,9 @@ pub enum PointerKind {
16121612
SharedRef { frozen: bool },
16131613
/// Mutable reference. `unpin` indicates the absence of any pinned data.
16141614
MutableRef { unpin: bool },
1615-
/// Box. `unpin` indicates the absence of any pinned data.
1616-
Box { unpin: bool },
1615+
/// Box. `unpin` indicates the absence of any pinned data. `global` indicates whether this box
1616+
/// uses the global allocator or a custom one.
1617+
Box { unpin: bool, global: bool },
16171618
}
16181619

16191620
/// Note that this information is advisory only, and backends are free to ignore it.
@@ -1622,6 +1623,8 @@ pub enum PointerKind {
16221623
pub struct PointeeInfo {
16231624
pub size: Size,
16241625
pub align: Align,
1626+
/// If this is `None`, then this is a raw pointer, so size and alignment are not guaranteed to
1627+
/// be reliable.
16251628
pub safe: Option<PointerKind>,
16261629
}
16271630

‎compiler/rustc_ast/src/mut_visit.rs

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1604,7 +1604,10 @@ pub fn noop_visit_capture_by<T: MutVisitor>(capture_by: &mut CaptureBy, vis: &mu
16041604
}
16051605
}
16061606

1607-
/// Some value for the AST node that is valid but possibly meaningless.
1607+
/// Some value for the AST node that is valid but possibly meaningless. Similar
1608+
/// to `Default` but not intended for wide use. The value will never be used
1609+
/// meaningfully, it exists just to support unwinding in `visit_clobber` in the
1610+
/// case where its closure panics.
16081611
pub trait DummyAstNode {
16091612
fn dummy() -> Self;
16101613
}
@@ -1679,19 +1682,6 @@ impl DummyAstNode for Stmt {
16791682
}
16801683
}
16811684

1682-
impl DummyAstNode for Block {
1683-
fn dummy() -> Self {
1684-
Block {
1685-
stmts: Default::default(),
1686-
id: DUMMY_NODE_ID,
1687-
rules: BlockCheckMode::Default,
1688-
span: Default::default(),
1689-
tokens: Default::default(),
1690-
could_be_bare_literal: Default::default(),
1691-
}
1692-
}
1693-
}
1694-
16951685
impl DummyAstNode for Crate {
16961686
fn dummy() -> Self {
16971687
Crate {

0 commit comments

Comments
 (0)
Please sign in to comment.