15 lines
135 B
Rust
15 lines
135 B
Rust
|
// error-pattern: ret; in function returning non-nil
|
||
|
|
||
|
fn f() {
|
||
|
ret;
|
||
|
}
|
||
|
|
||
|
fn g() -> int {
|
||
|
ret;
|
||
|
}
|
||
|
|
||
|
fn main() {
|
||
|
f();
|
||
|
g();
|
||
|
}
|