llvm-project/flang/lib/Evaluate
peter klausler 3a1afd8c3d Rework DATA statement semantics to use typed expressions
Summary:
Updates recent work on DATA statement semantic checking in
flang/lib/Semantics/check-data.{h,cpp} to use the compiler's
internal representation for typed expressions rather than working
on the raw parse tree.  Saves the analyzed expressions for DATA
statement values as parse tree decorations because they'll soon be
needed in lowering.  Corrects wording of some error messages.

Fixes a bug in constant expression checking: structure constructors
are not constant expressions if they set an allocatable component
to anything other than NULL.

Includes infrastructure changes to make this work, some renaming
to reflect the fact that the implied DO loop indices tracked by
expression analysis are not (just) from array constructors, remove
some dead code, and improve some comments.

Reviewers: tskeith, sscalpone, jdoerfert, DavidTruby, anchu-rajendran, schweitz

Reviewed By: tskeith, anchu-rajendran, schweitz

Subscribers: llvm-commits, flang-commits

Tags: #flang, #llvm

Differential Revision: https://reviews.llvm.org/D78834
2020-04-25 10:29:34 -07:00
..
CMakeLists.txt [Flang] fix dependency issues after D78215 2020-04-21 20:32:11 +01:00
call.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
character.h [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
characteristics.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
check-expression.cpp Rework DATA statement semantics to use typed expressions 2020-04-25 10:29:34 -07:00
common.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
complex.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
constant.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
expression.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
fold-character.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
fold-complex.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
fold-implementation.h [flang] Add message formatting for std::int64_t 2020-04-03 17:28:23 -07:00
fold-integer.cpp [flang] Add message formatting for std::int64_t 2020-04-03 17:28:23 -07:00
fold-logical.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
fold-real.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
fold.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
formatting.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
host.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
host.h [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
int-power.h [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
integer.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
intrinsics-library-templates.h [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
intrinsics-library.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
intrinsics.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
logical.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
real.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
shape.cpp [flang] Add message formatting for std::int64_t 2020-04-03 17:28:23 -07:00
static-data.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
tools.cpp [flang] Reformat with latest clang-format and .clang-format 2020-03-28 21:00:16 -07:00
type.cpp [flang] Compute sizes and offsets for symbols 2020-04-23 14:54:34 -07:00
variable.cpp Rework DATA statement semantics to use typed expressions 2020-04-25 10:29:34 -07:00