Skip to content

Commit ed9457c

Browse files
committed
[flang][test] Recognize !$acc and !$omp spelled with capital letters
If there are any continuation lines in the source, they will be printed using capital letters (at least in case of OpenMP). To avoid having them stripped out, recognize their spellings using capital letters as well.
1 parent 0a2116f commit ed9457c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

flang/test/Semantics/test_symbols.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
# Strips out blank lines and all comments except for "!DEF:", "!REF:", "!$acc" and "!$omp"
3030
with open(src, "r") as text_in:
3131
for line in text_in:
32-
text = re.sub(r"!(?![DR]EF:|\$omp|\$acc).*", "", line)
32+
text = re.sub(r"!(?![DR]EF:|\$[Oo][Mm][Pp]|\$[Aa][Cc][Cc]).*", "", line)
3333
text = re.sub(r"^\s*$", "", text)
3434
diff1 += text
3535

0 commit comments

Comments
 (0)