Skip to content

Commit 15db3f8

Browse files
Contiguity check
1 parent 6d0935c commit 15db3f8

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

flang/lib/Evaluate/call.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,16 @@ static void DetermineCopyInOutArgument(
281281
if (actual.isAlternateReturn()) {
282282
return;
283283
}
284+
const auto *dummyObj = std::get_if<characteristics::DummyDataObject>(&dummy.u);
285+
if (!dummyObj) {
286+
// Only DummyDataObject has the information we need
287+
return;
288+
}
289+
// Check actual contiguity, unless dummy doesn't care
290+
bool actualContiguous = dummyObj->ignoreTKR.test(common::IgnoreTKR::Contiguous)
291+
|| IsSimplyContiguous(actual, sc.foldingContext());
292+
bool actualVectorSubscript = HasVectorSubscript(actual);
293+
284294
// TODO
285295
}
286296

0 commit comments

Comments
 (0)