projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ce231b9
)
[flang] Add data to a new formatted message.
author
peter klausler
<pklausler@nvidia.com>
Wed, 8 Aug 2018 18:37:40 +0000
(11:37 -0700)
committer
peter klausler
<pklausler@nvidia.com>
Thu, 9 Aug 2018 17:17:43 +0000
(10:17 -0700)
Original-commit: flang-compiler/f18@
04b1ae9e68cb5e21393e834229bb6964169fee29
Reviewed-on: https://github.com/flang-compiler/f18/pull/165
Tree-same-pre-rewrite: false
flang/lib/evaluate/variable.cc
patch
|
blob
|
history
diff --git
a/flang/lib/evaluate/variable.cc
b/flang/lib/evaluate/variable.cc
index
adaaf4a
..
ba6aff3
100644
(file)
--- a/
flang/lib/evaluate/variable.cc
+++ b/
flang/lib/evaluate/variable.cc
@@
-168,7
+168,8
@@
std::optional<std::string> Substring::Fold(FoldingContext &context) {
std::int64_t len = str->size();
if (ubi > len) {
context.messages.Say(
- "upper bound on substring (%jd) is greater than character length (%jd)"_en_US);
+ "upper bound on substring (%jd) is greater than character length (%jd)"_en_US,
+ static_cast<std::intmax_t>(ubi), static_cast<std::intmax_t>(len));
ubi = len;
last_ = SubscriptIntegerExpr{ubi};
}