ITADN

Fix JET name collisions in @resumable expansion

#159Pull RequestKrastanov-agent 创建于 2026-04-01
K
Krastanov-agentcommented
## Summary - make top-level generated names in `@resumable` collision-resistant under JET/Revise replay - keep the fix minimal by changing only the generated binding names - preserve the current inference path from PR #147 ## Root cause `JET.report_package` replays top-level definitions through Revise/JuliaInterpreter. In that path, plain `gensym()`-derived top-level bindings from separate `@resumable` expansions can collide, which makes different helper methods and generated types share the same name. That is why `only(methods(inferfn, Tuple))` started failing after PR #147: it was seeing multiple methods attached to a collided helper binding, not a genuine ambiguity in the resumable function being analyzed. ## Verification Reproduced and fixed with a clean direct CLI run, outside the package test runner: ```julia using JET, QuantumSavory rep = JET.report_package(QuantumSavory; target_modules=(QuantumSavory,)) length(JET.get_reports(rep)) == 0 ```
合并状态:未合并 1 条评论