Skip to content

Fix type checking passing nil as a block#356

Merged
soutaro merged 1 commit intomasterfrom
nil-block-pass
Mar 27, 2021
Merged

Fix type checking passing nil as a block#356
soutaro merged 1 commit intomasterfrom
nil-block-pass

Conversation

@soutaro
Copy link
Owner

@soutaro soutaro commented Mar 27, 2021

Passing nil as a block doesn't give a block.

[1,2,3].each(&nil)        # Returns an Enumerator because block is not given!

Fixes #268.

@soutaro soutaro merged commit 17b78c9 into master Mar 27, 2021
@soutaro soutaro deleted the nil-block-pass branch March 27, 2021 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

steep check: &nil is treated as block

1 participant