Another test for typestate and expr_fn
This commit is contained in:
parent
28459ca0eb
commit
d832f7abec
1 changed files with 10 additions and 0 deletions
10
src/test/compile-fail/fn-expr-typestate-2.rs
Normal file
10
src/test/compile-fail/fn-expr-typestate-2.rs
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
// error-pattern:Unsatisfied precondition
|
||||||
|
// xfail-stage0
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
auto j = (fn () -> int {
|
||||||
|
let int i;
|
||||||
|
ret i;
|
||||||
|
})();
|
||||||
|
log_err j;
|
||||||
|
}
|
Loading…
Reference in a new issue