Test for #1789: Abnormal exit with missing return

Must have been fixed by fix for #1779