You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 16, 2023. It is now read-only.
It is a common typo to forget to call a function, but instead just leave the closure there, especially when doing refactoring etc. Thus, this rule will avoid this.
What type of rule is this?
Warns about a potential problem
Example code
Example1:InkWell(
onTap: () => _handle, // BAD
onTap: () =>_handle(), // GOOD
onTap: _handle, // GOOD
)
void_handle() { ... }
Example 2:
extension Ext on List {
void myFunction(int a) { ... }
}
Something(
someCallback: (a) => myList.myFunction, // BAD
someCallback: (a) => myList.myFunction(a), // GOOD
someCallback: myList.myFunction, // GOOD
)
### Participation
- [X] I am willing to submit a pull request to implement this rule.
### Additional comments
_No response_
The text was updated successfully, but these errors were encountered:
Rule details
It is a common typo to forget to call a function, but instead just leave the closure there, especially when doing refactoring etc. Thus, this rule will avoid this.
What type of rule is this?
Warns about a potential problem
Example code
Example 2:
The text was updated successfully, but these errors were encountered: