]> git.lizzy.rs Git - rust.git/commit
suggest `is_empty` for collections when casting to `bool`
authorEzra Shaw <ezrasure@outlook.com>
Sun, 15 Jan 2023 02:51:52 +0000 (15:51 +1300)
committerEzra Shaw <ezrasure@outlook.com>
Sun, 15 Jan 2023 09:17:54 +0000 (22:17 +1300)
commit92ced4a12e60811b67ed98c79c77c151581b7e07
treebe8e660da97735558301d751c47b109ffce24b58
parentb8f9cb345ab1401f2fbd14cc23f64dda9dd2314e
suggest `is_empty` for collections when casting to `bool`
compiler/rustc_hir_typeck/src/cast.rs
tests/ui/cast/cast-as-bool.rs
tests/ui/cast/cast-as-bool.stderr
tests/ui/cast/issue-106883-is-empty.rs [new file with mode: 0644]
tests/ui/cast/issue-106883-is-empty.stderr [new file with mode: 0644]