summaryrefslogtreecommitdiffstats
path: root/examples/18_ownership_error.rs
diff options
context:
space:
mode:
Diffstat (limited to 'examples/18_ownership_error.rs')
-rw-r--r--examples/18_ownership_error.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/examples/18_ownership_error.rs b/examples/18_ownership_error.rs
new file mode 100644
index 0000000..0e791c6
--- /dev/null
+++ b/examples/18_ownership_error.rs
@@ -0,0 +1,6 @@
+fn main () {
+ let x = box 2;
+ let y = x;
+ let z = x;
+}
+