Skip to content

[linter] no_await_no_async #59814

@stephane-archer

Description

@stephane-archer

if the last await is deleted from a function, the function should not be async

void foo(String bar) async { // should ask for deleting the async keyword
// await Future.delay(Duration(second: 2));
print(bar);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3A lower priority bug or feature requestarea-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.devexp-linterIssues with the analyzer's support for the linter packagetype-enhancementA request for a change that isn't a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions