Repository navigation
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryRust Confidence Score: 5/5No blocking failure remains. No accepted blocking findings remain.
What T-Rex did
Reviews (2): Last reviewed commit: "fix: drop the trait binding when a Rust ..." | Re-trigger Greptile |
|
Both findings addressed in b03a062, but they landed differently — one I could prove, one I could not. Trait fallback binds unrelated names — confirmed and fixed. You were right, and it is the same shadow-binding this PR exists to stop, just in the trait lane.
Regression test added: two same-named Inline chains retain shadow candidates — guard applied, but unproven.
However, I could not build a fixture that actually reaches it, and I want to be straight about that rather than imply otherwise. In the shapes I tried, the So: the guard is in as defence-in-depth. If you have a corpus shape that reaches it, I would like to see it and will turn it into a real test. Rust + class-ingest + trait/override suites: 1097 passed. |
|
@coderabbitai full review @greptile-apps review All review threads on this PR have been answered inline: findings implemented, or explicitly rebutted with the reasoning. Please re-assess against the current head and confirm whether this is ready to merge. |
Rate Limit Exceeded
|
b03a062 to
6c1aebd
Compare
6c1aebd to
3ec045a
Compare
cb3c93a
into
fix/rust-super-self-prefix-resolution
Closes #1082.
Change
The issue's framing was the design: both sites classify the same thing, so both must be able to say "no qn names this module" rather than return a spelling.
_rust_walk_modsconflated the two cases in one condition:They are not the same. No redirect means attach by name; a redirect whose target the qn scheme cannot key means nothing here is the module's referent. Split, and return
Nonefor the second._rust_attachhad the identical fall-through and gets the identical treatment.Nonethen propagates through_rust_join_mods→_rust_resolve_relative/_rust_rewrite_crate_path→_rewrite_rust_local_use_path, and each consumer does the right thing with it:_try_resolve_rust_module_qualifiedand_resolve_rust_prefixed_pathreturn a decided drop — never an undecided fall-through, which would let a bare-name trie guess find the shadow anyway.usestorage skips the binding entirely. Recording the raw spelling would externalise it into a phantom module node (fix: Rust crate::/super::/self:: use paths never resolve, so trait impls link to phantom externals and lose all OVERRIDES edges #1007); recording the name-derived one would bind the shadow.Tests
codebase_rag/tests/test_rust_unrepresentable_path_target.pycovers all three unrepresentable formspath_attribute_qn_partsrejects — absolute path, Windows separator, climb above the repo root — each asserting no edge to the undeclaredsrc/helpers.rsshadow, plus two controls:#[path]at all still binds the named module — the case the buggy branch conflated it withThree fail without the fix; both controls pass either way.
Rust + import-parsing + class-ingest suites: 952 passed.
tyclean.