Skip to content

Files

Latest commit

 

History

History
26 lines (17 loc) · 490 Bytes

Style-EmptyLambdaParameter.md

File metadata and controls

26 lines (17 loc) · 490 Bytes

Pattern: Empty lambda parameter with parentheses

Issue: -

Description

This rule checks for parentheses for empty lambda parameters. Parentheses for empty lambda parameters do not cause syntax errors, but they are redundant.

Examples

# bad
-> () { do_something }

# good
-> { do_something }

# good
-> (arg) { do_something(arg) }

Further Reading