Make type parameters not implicitly copyable, even if they have the Copy bound.
Consider: T:Copy could be bound to ~T, which is not implicitly copyable.
This commit is contained in:
parent
e7b0b71197
commit
a9012a2ad1
1 changed files with 1 additions and 1 deletions
|
|
@ -2273,7 +2273,7 @@ pub fn type_contents(cx: ctxt, ty: t) -> TypeContents {
|
|||
for type_param_def.bounds.builtin_bounds.each |bound| {
|
||||
debug!("tc = %s, bound = %?", tc.to_str(), bound);
|
||||
tc = tc - match bound {
|
||||
BoundCopy => TypeContents::nonimplicitly_copyable(cx),
|
||||
BoundCopy => TypeContents::noncopyable(cx),
|
||||
BoundStatic => TypeContents::nonstatic(cx),
|
||||
BoundOwned => TypeContents::nonowned(cx),
|
||||
BoundConst => TypeContents::nonconst(cx),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue