aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/ModuleBuilder.cpp
diff options
context:
space:
mode:
authorJean Perier <jperier@nvidia.com>2022-06-13 17:34:29 +0200
committerValentin Clement <clementval@gmail.com>2022-06-13 17:35:03 +0200
commitc8a9afe7c81bc874debbe319f3cf6b7b89f90aa2 (patch)
tree8c843ad844fd93fa0b2695103cca64d4791233f1 /clang/lib/CodeGen/ModuleBuilder.cpp
parent1054a7318788beb99536d84b34f84fccf2289769 (diff)
downloadllvm-c8a9afe7c81bc874debbe319f3cf6b7b89f90aa2.zip
llvm-c8a9afe7c81bc874debbe319f3cf6b7b89f90aa2.tar.gz
llvm-c8a9afe7c81bc874debbe319f3cf6b7b89f90aa2.tar.bz2
[flang] Handle reversed bounds and negative length in inlined allocation
ALLOCATE statement allows reversed bounds (see Fortran 2018 9.7.1.2 point 1) in which case the extents are zero. The same applies for the character length provided in the type spec that can be negative. In which case the new length is zero. Use genMaxWithZero to deal with these cases. This patch is part of the upstreaming effort from fir-dev branch. Reviewed By: jeanPerier, PeteSteinfeld Differential Revision: https://reviews.llvm.org/D127617 Co-authored-by: Jean Perier <jperier@nvidia.com>
Diffstat (limited to 'clang/lib/CodeGen/ModuleBuilder.cpp')
0 files changed, 0 insertions, 0 deletions