https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104970
--- Comment #7 from Martin Sebor <msebor at gcc dot gnu.org> --- The dollar sign in the internal attr_access string implies a VLA bound and the attr_access::vla_bounds() function queries the VLA bounds. That should make it possible to distinguish the two cases. Unlike the top-level VLA [N] notation which (unfortunately) implies no size constraint on the actual argument, attribute access is meant to imply that the array must have at least N elements (i.e., it's equivalent to [static N]). As an aside, the tests cases in r12-6480 exercise only a small subset of possible use cases: BDOS mode 0 results for calls to a function with attribute access with either a dynamic size (known and unknown result) and a constant size equal to array size. There are many more use cases that aren't being tested that should be (e.g., larger or smaller arrays of constant size than the size argument indicates with BDOS modes other than 0).