Forum: Ruby-core [ruby-trunk - Bug #8884][Open] `caller(1, nil)` raises a runtime error while its reference says its

9278c3a06b8d8752fb913dea93f959c1?d=identicon&s=25 gfx (Goro Fuji) (Guest)
on 2013-09-10 03:45
(Received via mailing list)
Issue #8884 has been reported by gfx (Goro Fuji).

----------------------------------------
Bug #8884: `caller(1, nil)` raises a runtime error while its reference
says its signature as `caller(start=1, length=nil)`
https://bugs.ruby-lang.org/issues/8884

Author: gfx (Goro Fuji)
Status: Open
Priority: Normal
Assignee:
Category:
Target version:
ruby -v: ruby 2.0.0p247 (2013-06-27 revision 41674)
[x86_64-darwin12.4.0]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


> $ ruby -e 'caller(1, nil)'
> -e:1:in `caller': no implicit conversion from nil to integer (TypeError)
>  from -e:1:in `<main>'

Either the behaviour or the document looks wrong; I don't know which is
wrong, though.
B99311b48290f8ee37311890a8edfb1d?d=identicon&s=25 sorah (Shota Fukumori) (Guest)
on 2013-09-10 03:49
(Received via mailing list)
Issue #8884 has been updated by sorah (Shota Fukumori).

Status changed from Open to Assigned
Assignee set to ko1 (Koichi Sasada)

This patch fixes: https://gist.github.com/sorah/6503895

I'll commit this if doc is correct.
----------------------------------------
Bug #8884: `caller(1, nil)` raises a runtime error while its reference
says its signature as `caller(start=1, length=nil)`
https://bugs.ruby-lang.org/issues/8884#change-41703

Author: gfx (Goro Fuji)
Status: Assigned
Priority: Normal
Assignee: ko1 (Koichi Sasada)
Category:
Target version:
ruby -v: ruby 2.0.0p247 (2013-06-27 revision 41674)
[x86_64-darwin12.4.0]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


> $ ruby -e 'caller(1, nil)'
> -e:1:in `caller': no implicit conversion from nil to integer (TypeError)
>  from -e:1:in `<main>'

Either the behaviour or the document looks wrong; I don't know which is
wrong, though.
F1d6cc2b735bfd82c8773172da2aeab9?d=identicon&s=25 Nobuyoshi Nakada (nobu)
on 2013-09-10 07:29
(Received via mailing list)
Issue #8884 has been updated by nobu (Nobuyoshi Nakada).


Seems fine.
----------------------------------------
Bug #8884: `caller(1, nil)` raises a runtime error while its reference
says its signature as `caller(start=1, length=nil)`
https://bugs.ruby-lang.org/issues/8884#change-41709

Author: gfx (Goro Fuji)
Status: Assigned
Priority: Normal
Assignee: ko1 (Koichi Sasada)
Category:
Target version:
ruby -v: ruby 2.0.0p247 (2013-06-27 revision 41674)
[x86_64-darwin12.4.0]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


> $ ruby -e 'caller(1, nil)'
> -e:1:in `caller': no implicit conversion from nil to integer (TypeError)
>  from -e:1:in `<main>'

Either the behaviour or the document looks wrong; I don't know which is
wrong, though.
B99311b48290f8ee37311890a8edfb1d?d=identicon&s=25 sorah (Shota Fukumori) (Guest)
on 2013-09-10 07:40
(Received via mailing list)
Issue #8884 has been updated by sorah (Shota Fukumori).

Backport changed from 1.9.3: UNKNOWN, 2.0.0: UNKNOWN to 1.9.3: UNKNOWN,
2.0.0: REQUIRED

documentation on 2.0.0 is same, so flagging as backport onto 2.0.0
needed.
----------------------------------------
Bug #8884: `caller(1, nil)` raises a runtime error while its reference
says its signature as `caller(start=1, length=nil)`
https://bugs.ruby-lang.org/issues/8884#change-41711

Author: gfx (Goro Fuji)
Status: Closed
Priority: Normal
Assignee: ko1 (Koichi Sasada)
Category:
Target version:
ruby -v: ruby 2.0.0p247 (2013-06-27 revision 41674)
[x86_64-darwin12.4.0]
Backport: 1.9.3: UNKNOWN, 2.0.0: REQUIRED


> $ ruby -e 'caller(1, nil)'
> -e:1:in `caller': no implicit conversion from nil to integer (TypeError)
>  from -e:1:in `<main>'

Either the behaviour or the document looks wrong; I don't know which is
wrong, though.
This topic is locked and can not be replied to.