[flang] Handle structure constructor in entity-decl
As with array constructors, we can encounter a decl-type-spec for a structure-constructor while the decl-type-spec for the type-declaration-stmt is still active. So here too we need to save and restore the state. In this case, it is done in DeclarationVisitor, so add SetDeclTypeSpecState() to get and set the state. Example where this occurs: ``` type(t(2)) :: x = t(2)() ``` Original-commit: flang-compiler/f18@aa5ca8d7b21d75ecd3c66a59589efd3ebb66af48 Reviewed-on: https://github.com/flang-compiler/f18/pull/249 Tree-same-pre-rewrite: false
Loading
Please sign in to comment