[flang] Check constant POS/LEN arguments IBITS even when not both constant
authorPeter Klausler <pklausler@nvidia.com>
Thu, 29 Jun 2023 21:02:18 +0000 (14:02 -0700)
committerPeter Klausler <pklausler@nvidia.com>
Mon, 3 Jul 2023 20:04:14 +0000 (13:04 -0700)
commit6c5ba7cddfa2210e9ddb12ab6f016b84db9a8b23
treed2b0abf30225a0fd219735a83b629d2a1ae7c41d
parent58d7484360e7987fec6f893da4b3e36da04bb643
[flang] Check constant POS/LEN arguments IBITS even when not both constant

Apply compile-time checks to the values supplied for the POS and LEN
arguments of the IBITS intrinsic function even when only one of them
is a known constant.

Differential Revision: https://reviews.llvm.org/D154376
flang/lib/Evaluate/fold-integer.cpp
flang/test/Evaluate/errors01.f90