2 Commits

Author SHA1 Message Date
Peter Klausler
325bd52893 [flang] More subscript triplet checking at compilation time
When a triplet's lower and upper bounds are the same, we can
check them without requiring a constant stride.

Differential Revision: https://reviews.llvm.org/D142943
2023-01-31 08:18:48 -08:00
Peter Klausler
10b990a03b [flang] Diagnose known out-of-range subscripts in more circumstances
Semantics can catch out-of-range subscript values already when they
appear in DATA statement objects and constant folding of name constant
array indexing; this patch fills the gap by checking known constant
subscript values in other contexts.

Differential Revision: https://reviews.llvm.org/D142764
2023-01-28 15:27:17 -08:00