Skip to content

Commit 9e609b1

Browse files
committed
fix: flip the condition in strip_comment for fixed format
1 parent 3cf8f29 commit 9e609b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fortls/parsers/internal/parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1137,7 +1137,7 @@ def get_code_line(
11371137
def strip_comment(self, line: str) -> str:
11381138
"""Strip comment from line"""
11391139
if self.fixed:
1140-
if FRegex.FIXED_COMMENT.match(line) and FRegex.FIXED_OPENMP.match(line):
1140+
if FRegex.FIXED_COMMENT.match(line) and not FRegex.FIXED_OPENMP.match(line):
11411141
return ""
11421142
else:
11431143
if FRegex.FREE_OPENMP.match(line) is None:

0 commit comments

Comments
 (0)