Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

enebo
Copy link
Member

@enebo enebo commented Aug 7, 2025

This allows define_method to be converted to a method with nested blocks so long as those nested blocks do not get captures from outside define_method.

As it stands this hurts performance:
https://gist.github.com/enebo/7256fd51d3f0ebb49d433f2bc3e77d02

It appears that something is not optimizing correctly for these converted blocks. nested capture def should be the performance for nested capture and for sure should be faster than just invoking nested capture with the optimization disabled.

This allows define_method to be converted to a method with
nested blocks so long as those nested blocks do not get
captures from outside define_method.

As it stands this hurts performance:
https://gist.github.com/enebo/7256fd51d3f0ebb49d433f2bc3e77d02

It appears that something is not optimizing correctly for
these converted blocks.  `nested capture def` should be the
performance for `nested capture` and for sure should be faster
than just invoking `nested capture` with the optimization disabled.
@enebo enebo added this to the JRuby 10.0.3.0 milestone Aug 7, 2025
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.

1 participant

Morty Proxy This is a proxified and sanitized view of the page, visit original site.