Skip to content

Analyzer: strict_raw_types difficult to comply with atomically #36445

Open
@srawlins

Description

@srawlins

Basically I'd like to split up the STRICT_RAW_TYPE code into a few more, to make it an easier pill to swallow. Teams can either make their code compliant incrementally, or opt out of individual checks they feel they are too onerous. Something like:

  • STRICT_RAW_TYPE_LIST_LITERAL for var foo = [];
  • STRICT_RAW_TYPE_MAP_LITERAL for var foo = {};
  • STRICT_RAW_TYPE_SET_LITERAL
  • STRICT_RAW_TYPE_NAME for foo is List, foo as List, List foo, Future main(), main(List args), perhaps
  • STRICT_RAW_TYPE_CONSTRUCTOR for Future.value(), Set()

Metadata

Metadata

Assignees

No one assigned

    Labels

    P4area-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.devexp-warningIssues with the analyzer's Warning codesstrict-analysis-neededMark issues where strict-raw-types, strict-inference and similar analysis options were helpfultype-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