Skip to content

Update nightly toolchain to 2024-09-08#78

Merged
coord-e merged 2 commits intomainfrom
coord-e/claude/nightly-2024-09-08
May 10, 2026
Merged

Update nightly toolchain to 2024-09-08#78
coord-e merged 2 commits intomainfrom
coord-e/claude/nightly-2024-09-08

Conversation

@coord-e
Copy link
Copy Markdown
Owner

@coord-e coord-e commented May 6, 2026

#26

@coord-e coord-e force-pushed the coord-e/claude/nightly-2024-09-08 branch 2 times, most recently from b37f058 to ef44365 Compare May 10, 2026 04:16
@coord-e coord-e marked this pull request as ready for review May 10, 2026 04:18
@coord-e coord-e requested a review from Copilot May 10, 2026 04:18
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the repository’s pinned Rust nightly to nightly-2024-09-08 and adjusts Thrust’s rustc-internal integrations and UI tests to compile and run on the newer compiler.

Changes:

  • Bump pinned toolchain from nightly-2024-03-08 to nightly-2024-09-08.
  • Update rustc API usages across analysis/refinement code (HIR body access, Instance::try_resolve, MIR dataflow APIs, token kinds, fn ptr ty representation).
  • Add a MIR normalization workaround for SwitchInt discriminant ordering, and stabilize UI tests by clearing THRUST_SOLVER_ARGS.

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
rust-toolchain.toml Pins the project to nightly-2024-09-08 and keeps required components.
src/refine/template.rs Adapts type translation to updated rustc type APIs (folder trait, fn ptr representation, unit type access).
src/main.rs Adjusts parser construction to match updated rustc_parse API return type.
src/annot.rs Updates token kind usage for path separators on newer rustc.
src/analyze/local_def.rs Updates HIR access patterns, instance resolution, and adds SwitchInt discriminant order normalization before running dataflow.
src/analyze/basic_block/drop_point.rs Updates graph successor trait import to match rustc changes.
src/analyze/basic_block.rs Updates const-eval APIs and iterator handling changes for call args / deref APIs.
src/analyze/annot_fn.rs Updates HIR body access and instance resolution to newer rustc APIs.
src/analyze.rs Updates discriminant evaluation conversion and FnSig field rename (unsafetysafety).
std.rs Adds a new extern spec for PartialEq::eq.
tests/ui/pass/iterators/range.rs Clears THRUST_SOLVER_ARGS to stabilize solver invocation during UI testing.
tests/ui/fail/iterators/range.rs Clears THRUST_SOLVER_ARGS to stabilize solver invocation during UI testing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread std.rs Outdated
Comment on lines +275 to +283
// TODO: this is too restrictive and impls should be able to choose the definition of equality
#[thrust::extern_spec_fn]
#[thrust_macros::requires(true)]
#[thrust_macros::ensures(result == (x == y))]
fn _extern_spec_partialeq_eq<T>(x: &T, y: &T) -> bool
where T: thrust_models::Model + PartialEq, T::Ty: PartialEq
{
PartialEq::eq(x, y)
}
Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will not make verification unsound because the eq impl is checked against this type. And I'm saying this is too restrictive and this should be fixed finally.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#82

claude and others added 2 commits May 10, 2026 16:18
Update rust-toolchain.toml to nightly-2024-09-08 and fix compilation
errors from API changes in this nightly version:

- Rename WithSuccessors to Successors (rustc_data_structures::graph)
- Rename TypeFolder::interner to cx
- TyKind::FnPtr now takes (sig_tys, hdr) instead of (sig)
- Remove Ty::new_unit in favor of tcx.types.unit
- body_owned_by / maybe_body_owned_by now return &Body directly
- boxed_ty() now returns Option<Ty>
- TyKind::RawPtr now takes (ty, mutbl) instead of TypeAndMut
- MaybeInitializedPlaces::new takes &move_data instead of &MoveDataParamEnv
- try_to_int/try_to_u32 renamed to to_int/to_u32
- sig.unsafety renamed to sig.safety
- const_eval_resolve takes DUMMY_SP instead of None
- builtin_deref returns Option<Ty> instead of Option<TypeAndMut>
- TokenKind::ModSep renamed to PathSep
- new_parser_from_source_str returns Result
- Instance::resolve renamed to Instance::try_resolve

Also add normalize_switch_int_discriminant_order() to handle the new
assertion in nightly-2024-09-08 that SwitchInt targets must be in
AdtDef::discriminants order, and skip unknown defs gracefully when
Instance::try_resolve resolves to blanket impls not tracked by thrust.

https://claude.ai/code/session_01URrtbSTUKNrVKLK2MNLBFc

Fix clippy warning and apply cargo fmt

- Use .iter() instead of .into_iter() on Box<[T]> to avoid ambiguity
  with the Rust 2024 edition semantics change (boxed_slice_into_iter)
- Apply cargo fmt formatting

https://claude.ai/code/session_01URrtbSTUKNrVKLK2MNLBFc
@coord-e coord-e force-pushed the coord-e/claude/nightly-2024-09-08 branch from ef44365 to f029193 Compare May 10, 2026 07:19
@coord-e coord-e merged commit 8378e9d into main May 10, 2026
6 checks passed
@coord-e coord-e deleted the coord-e/claude/nightly-2024-09-08 branch May 10, 2026 07:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants