[flang] Allow for access-stmt before namelist-stmt
authorTim Keith <tkeith@nvidia.com>
Tue, 25 Feb 2020 02:55:53 +0000 (18:55 -0800)
committerTim Keith <tkeith@nvidia.com>
Tue, 25 Feb 2020 23:22:13 +0000 (15:22 -0800)
commitde066a2756b78474eee98b476e6b83bb68788936
treeec79d17f10dd540f22f5c942a84dd4c6d2a6cb79
parent0855c45400f88afcaf3e4def7d5bb4abee502aa3
[flang] Allow for access-stmt before namelist-stmt

You can declare a name in an access statement and then declare it as
a namelist group name. We weren't allowing that because we didn't
convert a symbol with UnknownDetails to one with NamelistDetails.

Fixes flang-compiler/f18#1022.

Original-commit: flang-compiler/f18@a759204db583d337dda886acf748e0fe135c6259
Reviewed-on: https://github.com/flang-compiler/f18/pull/1023
flang/lib/Semantics/resolve-names.cpp
flang/test/Semantics/resolve40.f90