ah, that's it! as spec says, D determines function return value from the first 'return' statement it seen. in your case this is `return;`,
so function return type is determined to be `void`.

if you doing `auto` functions, try to arrange your code so the first
`return` returning the actual value.

besides, your code is wrong anyway, 'cause you can't have function that returns both "nothing" and "something". your first `return;` should either return something, or must be changed to throwing some exception.

How I can terminate program? First return I used to terminate app if config file is exists.

Reply via email to