Revert "Fix evaluation order issue in f(**h, &h.delete(key))"

This reverts commit 07d3bf4832.

No failures in the pull request CI, but there are now allocation
test failures.
This commit is contained in:
Jeremy Evans 2024-09-18 11:26:10 -07:00
parent 07d3bf4832
commit 9c12c39ed1
3 changed files with 25 additions and 84 deletions

View file

@ -374,21 +374,6 @@ class TestCall < Test::Unit::TestCase
assert_equal({splat_modified: false}, b)
end
def test_kwsplat_block_eval_order
def self.t(**kw, &b) [kw, b] end
pr = ->{}
h = {a: pr}
a = []
ary = t(**h, &h.delete(:a))
assert_equal([{a: pr}, pr], ary)
h = {a: pr}
ary = t(*a, **h, &h.delete(:a))
assert_equal([{a: pr}, pr], ary)
end
def test_kwsplat_block_order
o = Object.new
ary = []