Fix namespace::clean and DBIx::Class weak closure tests#782
Merged
Conversation
52ed45b to
4d4acb4
Compare
Normalize parser token mismatch diagnostics to Perl-style syntax errors, preserve bareword filehandle IO slot identity across open, and restore IO slots through Package::Stash glob assignment. Generated with Codex (https://openai.com/codex) Co-Authored-By: Codex <codex@openai.com>
DBIx::Class::Storage::BlockRunner weakens a fresh closure argument copy before invoking it. Perl keeps the caller's strong lexical alive, but PerlOnJava's CODE weak-ref sweep cleared the weak copy immediately when the closure had no counted owners. Teach the CODE weak-ref cleanup path to preserve weak CODE refs while a current live scalar still points at the same RuntimeCode, without preserving stale deleted stash slots used by Sub::Quote cleanup. Generated with Codex (https://openai.com/codex) Co-Authored-By: Codex <codex@openai.com>
When tie receives a class-name string, resolve the TIE* constructor directly through package method lookup instead of routing through generic string method dispatch. Generic dispatch treats a same-named IO slot as a filehandle object, which regressed op/tie.t after bareword filehandles began preserving IO::File identity. Add a focused regression test for fileno FOO followed by tie @array, "FOO". Generated with [OpenAI Codex](https://openai.com/codex) Co-Authored-By: OpenAI Codex <codex@openai.com>
9456dcd to
8ee8047
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
weaken(my $copy = shift)on captured closuresVerification
timeout 1200 make-> passtimeout 600 ./jcpan -t namespace::clean-> pass, 2099 teststimeout 240 jperl t/100extra_source.t-> passtimeout 240 jperl t/100populate.t-> passtimeout 1200 ./jcpan -t DBIx::Class-> timed out after 20 minutes with no failures throught/86might_have.t; earlier failurest/100extra_source.t,t/100populate.t, andt/101populate_rs.tnow pass