mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 23:12:02 +00:00
Add an XFAILed test for blocks that result in functions
This commit is contained in:
parent
d2d42fd4c7
commit
a4f8de382a
15
src/test/run-pass/expr-block-fn.rs
Normal file
15
src/test/run-pass/expr-block-fn.rs
Normal file
@ -0,0 +1,15 @@
|
||||
// xfail-boot
|
||||
// xfail-stage0
|
||||
|
||||
fn test_fn() {
|
||||
type t = fn() -> int;
|
||||
fn ten() -> int {
|
||||
ret 10;
|
||||
}
|
||||
let t res = { ten };
|
||||
check (res() == 10);
|
||||
}
|
||||
|
||||
fn main() {
|
||||
test_fn();
|
||||
}
|
Loading…
Reference in New Issue
Block a user