Project

General

Profile

This project is closed and read-only.

Actions

Backport #8236

closed

super & named parameters bug

Backport #8236: super & named parameters bug

Added by marcandre (Marc-Andre Lafortune) over 13 years ago. Updated over 13 years ago.


Description

=begin
class Base
def foo(*args)
p args
end
end

class A < Base
def foo(arg, bar: 'x')
super
end
end
A.new.foo 42 # => [42, {:bar=>"x"}] (ok)

class B < Base
def foo(*args, bar: 'x')
super
end
end
B.new.foo 42 # => [[42], [:bar, "x"]] (not ok, should be same)
=end

Updated by nobu (Nobuyoshi Nakada) over 13 years ago Actions #1

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

This issue was solved with changeset r40205.
Marc-Andre, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.


compile.c: append keyword hash to splat

  • compile.c (iseq_compile_each): append keyword hash to argument array
    to splat if needed. [ruby-core:54094] [Bug #8236]

Updated by nobu (Nobuyoshi Nakada) over 13 years ago Actions #2 [ruby-core:54129]

  • Description updated (diff)

Updated by nobu (Nobuyoshi Nakada) over 13 years ago Actions #3

  • Tracker changed from Bug to Backport
  • Project changed from Ruby to 15
  • Category deleted (core)
  • Status changed from Closed to Assigned
  • Assignee set to nagachika (Tomoyuki Chikanaga)

Updated by nagachika (Tomoyuki Chikanaga) over 13 years ago Actions #4

  • Status changed from Assigned to Closed

This issue was solved with changeset r40379.
Marc-Andre, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.


merge revision(s) 40205: [Backport #8236]

* compile.c (iseq_compile_each): append keyword hash to argument array
  to splat if needed.  [ruby-core:54094] [Bug #8236]
Actions

Also available in: PDF Atom