[flang] basic skeleton of assignment analyzer
remove needless template<> on some function overloads
dodge bogus compiler warning from gcc 8.1.0 only
stricter typing of expressions in symbols
adjust modfile12.f90 expected test results
add Unwrap, massage folding a bit
Use Unwrap to simplify folding
Move KindSelector analysis into expression semantics
fix crash
checkpoint
updates to TypeParamInquiry
support of %KIND type parameter inquiry
equality testing for expressions
checkpoint during PDT implementation
reformat
checkpoint derived type instantiation
checkpoint
resolve merge
debugging failed tests
fix failing resolve37.f90 test
all existing tests pass
clean up all build warnings
fix bug
update copyright dates
fix copyright dates
address review comments
review comment
merge with master after peeling off changes
bugfixing new feature
fix warning from old g++s
tweaks after merging with latest head
more bugfixing
making modfile17.f90 test work
Make kinds into expressions in symbol table types
big refactor for deferring kinds in intrinsic types
modfile17.f90 test passes
clean up TODOs
Simplify types as stored in scopes
Test KIND parameter default init expressions, debug them
Update copyright dates
address comments
remove dead line
address comments
Original-commit: flang-compiler/f18@1f43d0a04813dc02909e9952ee479d13f630df4c
Reviewed-on: https://github.com/flang-compiler/f18/pull/260
Tree-same-pre-rewrite: false
diff --git a/flang/lib/evaluate/intrinsics.cc b/flang/lib/evaluate/intrinsics.cc
index 77a47d5..6757da8 100644
--- a/flang/lib/evaluate/intrinsics.cc
+++ b/flang/lib/evaluate/intrinsics.cc
@@ -111,6 +111,7 @@
static constexpr TypePattern AnyChar{CharType, KindCode::any};
static constexpr TypePattern AnyLogical{LogicalType, KindCode::any};
static constexpr TypePattern AnyRelatable{RelatableType, KindCode::any};
+static constexpr TypePattern AnyIntrinsic{IntrinsicType, KindCode::any};
static constexpr TypePattern Anything{AnyType, KindCode::any};
// Match some kind of some intrinsic type(s); all "Same" values must match,
@@ -385,6 +386,7 @@
SameInt},
{"is_iostat_end", {{"i", AnyInt}}, DefaultLogical},
{"is_iostat_eor", {{"i", AnyInt}}, DefaultLogical},
+ {"kind", {{"x", AnyIntrinsic}}, DefaultInt},
{"lbound",
{{"array", Anything, Rank::anyOrAssumedRank}, SubscriptDefaultKIND},
KINDInt, Rank::vector},