Skip to content

[fix] define_method captured block propagation in JIT mode#9310

Merged
kares merged 1 commit intojruby:jruby-10.0from
kares:define_method_jit
Mar 28, 2026
Merged

[fix] define_method captured block propagation in JIT mode#9310
kares merged 1 commit intojruby:jruby-10.0from
kares:define_method_jit

Conversation

@kares
Copy link
Copy Markdown
Member

@kares kares commented Mar 16, 2026

an attempt at resolving #8946

@kares kares linked an issue Mar 16, 2026 that may be closed by this pull request
}
}

if (!blockGiven) {
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems quite ugly that we would need to be aware of the DefineMethodMethod here..

Copy link
Copy Markdown
Member

@headius headius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like an ok fix. I agree it's not great we have to know whether it's a DefineMethodMethod but there's a lot of binding code that is specific to each type of method. The long term approach would be to have the methods be responsible for building up the binding but we're not there yet.

@headius headius added this to the JRuby 10.0.5.0 milestone Mar 28, 2026
@kares kares marked this pull request as ready for review March 28, 2026 19:39
@kares kares merged commit 0d25672 into jruby:jruby-10.0 Mar 28, 2026
160 of 161 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

define_method conversion fails to yield after indy JIT

2 participants