Fixes https://github.com/llvm/llvm-project/issues/194596.
When the function result symbol is encountered while the compiler is
already completing the function result type, flang could recursively
re-enter _CompleteFunctionResultType()_ and crash on invalid code.
Instead of crashing on conflicting declarations, flang now reports an
“already declared” error and stops further recursion.