about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/back/write.rs
diff options
context:
space:
mode:
authorMaybe Waffle <waffle.lapkin@gmail.com>2022-02-25 23:34:25 +0300
committerMaybe Waffle <waffle.lapkin@gmail.com>2022-03-01 16:56:00 +0300
commit400d343796065e57e78d92b4cf74c78bec38452a (patch)
treec2afe0d6d352b5e5fc3b6efd43912b1fae728a8e /compiler/rustc_codegen_llvm/src/back/write.rs
parent4c7fb9efb7804e489bcf4fe1d3cdf0f7df3b0eff (diff)
downloadrust-400d343796065e57e78d92b4cf74c78bec38452a.tar.gz
rust-400d343796065e57e78d92b4cf74c78bec38452a.zip
Suggest adding `Copy` bound when Adt is moved out
Previously we've only suggested adding `Copy` bounds when the type being
moved/copied is a type parameter (generic). With this commit we also
suggest adding bounds when a type
- Can be copy
- All predicates that need to be satisfied for that are based on type
  params

i.e. we will suggest `T: Copy` for `Option<T>`, but won't suggest
anything for `Option<String>`.

Future work: it would be nice to also suggest adding `.clone()` calls
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/back/write.rs')
0 files changed, 0 insertions, 0 deletions