• Nate Bosch's avatar
    Remove an unnecessary assert (#129796) · 34c092f2
    Nate Bosch authored
    The type variable `T`, when used as an expression, will always be a
    `Type`. The type test `T is! List` is always true (as is `T is Type`).
    
    This expression will become a warning in the analyzer in some upcoming
    release of the Dart SDK.
    
    This `assert` was added in a PR which reapplied an earlier PR, however
    the earlier PR did not include this assert. I do not see any discussion
    indicating the intent of this assert.
    
    The impact of testing this `T` in any way is low - this is a private
    class so we can see all the uses and know that the only type bound to
    `T` is `Uri`. Avoid the upcoming diagnostic and remove the assert
    entirely. This maintains existing behavior but ignores the potential
    intent for the check.
    34c092f2
Name
Last commit
Last update
.github Loading commit data...
.vscode Loading commit data...
bin Loading commit data...
dev Loading commit data...
examples Loading commit data...
packages Loading commit data...
.ci.yaml Loading commit data...
.cirrus.yml Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CODEOWNERS Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
CONTRIBUTING.md Loading commit data...
LICENSE Loading commit data...
PATENT_GRANT Loading commit data...
README.md Loading commit data...
TESTOWNERS Loading commit data...
analysis_options.yaml Loading commit data...
dartdoc_options.yaml Loading commit data...
flutter_console.bat Loading commit data...