You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
warning: use of deprecated associated function core::num::<impl u32>::max_value: replaced by the MAX associated constant on this type #5110
warning: use of deprecated associated function `core::num::<impl u32>::max_value`: replaced by the `MAX` associated constant on this type
--> crates/pyrefly_util/src/tarjan.rs:183:1
|
183 | / define_index_type! {
184 | | struct NodeIdx = u32;
185 | | }
| |_^
|
= note: `#[warn(deprecated)]` on by default
= note: this warning originates in the macro `define_index_type` (in Nightly builds, run with -Z macro-backtrace for more info)
warning: use of deprecated associated function `core::num::<impl u32>::max_value`: replaced by the `MAX` associated constant on this type
--> crates/pyrefly_util/src/tarjan.rs:187:1
|
187 | / define_index_type! {
188 | | struct StackIdx = u32;
189 | | }
| |_^
|
= note: this warning originates in the macro `define_index_type` (in Nightly builds, run with -Z macro-backtrace for more info)
warning: use of deprecated associated function `core::num::<impl u32>::max_value`: replaced by the `MAX` associated constant on this type
--> crates/pyrefly_util/src/tarjan.rs:191:1
|
191 | / define_index_type! {
192 | | pub struct SccIdx = u32;
193 | | }
| |_^
|
Thanks for flagging this, and thanks @XinjieCui for picking it up! The deprecated call comes from the index_vec macro's default rather than tarjan.rs itself, so adding MAX_INDEX = u32::MAX as usize; to each of the three define_index_type! blocks fixes it without changing behaviour (0.1.4 is the latest index_vec, so an upgrade won't help). If your rustc doesn't show the warning yet, build with RUSTFLAGS="-W deprecated-in-future" to check before and after.
Hi @XinjieCui, just checking in on this one. Are you still planning to send a PR? No rush, but if you have moved on, let us know and we will pick it up.
Since we haven't heard back, I'm opening this up again for anyone who'd like to take it. The fix is in my earlier comment: add MAX_INDEX = u32::MAX as usize; to each of the three define_index_type! blocks in tarjan.rs. Thanks @XinjieCui, and feel free to jump back in if you still want it.
Activity
XinjieCui commentedon Oct 6, 2026
Hi, I'd like to work on this. #claim
github-actions commentedon Oct 6, 2026
@XinjieCui you've claimed this issue — it's now assigned to you. Thanks for picking it up! 🎉
shahhamdihassan commentedon Oct 13, 2026
Thanks for flagging this, and thanks @XinjieCui for picking it up! The deprecated call comes from the
index_vecmacro's default rather thantarjan.rsitself, so addingMAX_INDEX = u32::MAX as usize;to each of the threedefine_index_type!blocks fixes it without changing behaviour (0.1.4 is the latestindex_vec, so an upgrade won't help). If your rustc doesn't show the warning yet, build withRUSTFLAGS="-W deprecated-in-future"to check before and after.shahhamdihassan commentedon Oct 21, 2026
Hi @XinjieCui, just checking in on this one. Are you still planning to send a PR? No rush, but if you have moved on, let us know and we will pick it up.
shahhamdihassan commentedon Oct 28, 2026
Since we haven't heard back, I'm opening this up again for anyone who'd like to take it. The fix is in my earlier comment: add
MAX_INDEX = u32::MAX as usize;to each of the threedefine_index_type!blocks intarjan.rs. Thanks @XinjieCui, and feel free to jump back in if you still want it.Raresreras commentedon Oct 30, 2026
Hello, I would like to work on this issue
#claim
github-actions commentedon Oct 30, 2026
@Raresreras this issue is already claimed by @XinjieCui. Please coordinate with them before starting.