correct builtins type under function#6745
Conversation
📝 WalkthroughWalkthroughThe changes refactor PyFunctionNewArgs struct field signatures, converting OptionalArg types to Option, renaming defaults to argdefs, and enhance builtins resolution logic to fallback to vm.builtins.dict() with module unwrapping. The py_new constructor is updated to validate closure length against code.freevars. A test is added to verify that function \builtins resolves to a dict. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
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 |
|
Code has been automatically formatted The code in this PR has been formatted using:
git pull origin correct-builtins-type |
Summary by CodeRabbit
Refactor
Tests
✏️ Tip: You can customize this high-level summary in your review settings.