]> git.lizzy.rs Git - rust.git/commitdiff
Add a test for assignment of bare functions
authorBrian Anderson <banderson@mozilla.com>
Tue, 11 Oct 2011 19:13:39 +0000 (12:13 -0700)
committerBrian Anderson <banderson@mozilla.com>
Tue, 11 Oct 2011 20:40:31 +0000 (13:40 -0700)
Issue #1022

src/test/run-pass/fn-bare-anon-2.rs [new file with mode: 0644]

diff --git a/src/test/run-pass/fn-bare-anon-2.rs b/src/test/run-pass/fn-bare-anon-2.rs
new file mode 100644 (file)
index 0000000..0ea3807
--- /dev/null
@@ -0,0 +1,7 @@
+fn main() {
+    let f: fn#() = fn# () {
+        log "This is a bare function"
+    };
+    let g;
+    g = f;
+}
\ No newline at end of file