Why compiler allow to put unreachable code after return?

But javac behavior saves in such common situation:
if (foo) {
return foo
} else {
-foo = bar
+return bar
}
blabla
blabla
blabla
return foo

And you never write if (true) return not for debugging. if (true) not so harder to write.

Another non obvious place is missing ‘+’ in multiline strings on return. Like:
return “I thought It”
“would be one string”