Fldes Lszl wrote in post #1136082:
> Edoardo Rossi wrote in post #1136041:

> [1] pry(main)> puts a if a = 0.zero?
> NameError: undefined local variable or method `a' for main:Object
> from (pry):1:in `__pry__'
> [2] pry(main)> a
> => true
> [3] pry(main)>
>
> If anything that is defined gets into this inner scope and anything that
> is defined (or modified) inside the inner scope gets out, then this is
> not really a scope...

Another example, which doesn't create a noise like local variable in my first post.

(arup~>~)$ pry --simple-prompt
>> puts meth if eval('def meth;12;end').nil?
12
=> nil
>>