Skip to content

Commit d9fc949

Browse files
proggeramlugRalph
andauthored
chore(lint): allowlist the guarded GcHeader probe in collection_proto_thunks (#6659) (#6722)
#6659 (fac2bbe) added a `(ptr as *const u8).sub(GC_HEADER_SIZE) as *const GcHeader` obj_type probe in collection_proto_thunks.rs without an addr-class allowlist entry, so the address-classification audit (the `lint` gate) went red on main and on every open PR branched from it. The probe is correctly magnitude-classified — it runs only inside `if is_above_handle_band(ptr) && is_valid_obj_ptr(ptr as *const u8)`, so the pointer is never a handle-band small integer at the deref. Add the standard allowlist entry (same shape as the sibling object/* probes) with a follow-up note to migrate it to `addr_class::try_read_gc_header`. Restores lint to green; no functional change. Co-authored-by: Ralph <ralph@skelpo.com>
1 parent 6cf9366 commit d9fc949

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

scripts/addr_class_allowlist.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ crates/perry-runtime/src/object/global_this/ | * | pre-existing GcHeader probe p
137137
crates/perry-runtime/src/object/class_registry/ | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of class_registry.rs)
138138
crates/perry-runtime/src/object/descriptor_state.rs | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of object/mod.rs)
139139
crates/perry-runtime/src/object/to_string_tag.rs | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of object/mod.rs)
140+
crates/perry-runtime/src/object/collection_proto_thunks.rs | * | GcHeader obj_type probe guarded by is_above_handle_band + is_valid_obj_ptr (magnitude-classified before the deref); migrate to addr_class::try_read_gc_header in a follow-up (added in #6659)
140141
crates/perry-runtime/src/symbol/ | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of symbol.rs)
141142
crates/perry-runtime/src/typedarray/ | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of typedarray/mod.rs)
142143
crates/perry-runtime/src/process/ | * | pre-existing GcHeader probe predating addr_class; address validated by call-site guards (magnitude/registry/is_valid_obj_ptr) -- migrate to addr_class::try_read_gc_header in a follow-up (split of process.rs)

0 commit comments

Comments
 (0)