diff options
Diffstat (limited to 'src/test/ui/closures/coerce-unsafe-to-closure.rs')
-rw-r--r-- | src/test/ui/closures/coerce-unsafe-to-closure.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/test/ui/closures/coerce-unsafe-to-closure.rs b/src/test/ui/closures/coerce-unsafe-to-closure.rs new file mode 100644 index 000000000..78bdd36f9 --- /dev/null +++ b/src/test/ui/closures/coerce-unsafe-to-closure.rs @@ -0,0 +1,4 @@ +fn main() { + let x: Option<&[u8]> = Some("foo").map(std::mem::transmute); + //~^ ERROR E0277 +} |