Commit 47452b96 authored by Tim Keith's avatar Tim Keith
Browse files

[flang] Improve checking of structure constructor arguments

When a misparsed FunctionReference was converted to a StructureConstructor,
the components accessed were not checked for accessibility.

The conversion happens in expression analysis so that where the accessibity
must be checked. So move `CheckAccessibleComponent` to `tools.h` so that it
can be shared by `resolve-names.cpp` and `expression.cpp`.

Add FindModuleContaining to help implement this and use it other places.

Check that an access-spec can only appear in a module.

Remove some unnecessary "semantics::" qualifiers.

Original-commit: flang-compiler/f18@99ce156e49ec0847ce42a6d10f0a62664714092b
Reviewed-on: https://github.com/flang-compiler/f18/pull/1046
parent f30c0307
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment