about summary refs log tree commit diff
path: root/tests/ui/traits/copy-trait-implicit-copy.rs
blob: e06385587b4b54c0bd27dd5420c06737c6e75239 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
//! Tests that type parameters with the `Copy` are implicitly copyable.

//@ run-pass

/* Any copyright is dedicated to the Public Domain.
 * http://creativecommons.org/publicdomain/zero/1.0/ */

#![allow(dead_code)]

fn can_copy_copy<T: Copy>(v: T) {
    let _a = v;
    let _b = v;
}

pub fn main() {}