General

Profile

kodnin (David Boot)

  • Login: kodnin
  • Registered on: 09/16/2020
  • Last sign in: 10/02/2020

Issues

open closed Total
Assigned issues 0 0 0
Reported issues 0 1 1

Activity

09/26/2020

07:40 AM Ruby Bug #17193: Endless method definition doesn't work with lambdas in IRB
wanabe (_ wanabe) wrote in #note-1:
> I think this is an irb problem, not a ruby problem.
> ...
I can confirm that this works indeed.
```
$ ruby -e 'def bar() = ->(x) { x * x }; puts bar.(3)'
9
```
kodnin (David Boot)
07:22 AM Ruby Bug #17193 (Closed): Endless method definition doesn't work with lambdas in IRB
Endless method definition doesn't work with lambdas. Please check the attached screenshot.
``` ruby
def foo() = 123
# => :foo
foo
# => 123
def bar() = lambda { |x| x * x }
# I expected the method to be defined.
def bar() ...
kodnin (David Boot)

Also available in: Atom