Skip to content

Commit ca309cd

Browse files
committed
fix(parser): allow detection of compilers prefixed with path
1 parent 2227023 commit ca309cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ccdgen/__main__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def detect_compiler(line: str) -> str | None:
165165

166166
for token in line.split(' '):
167167
for compiler in COMPILERS:
168-
if token == compiler or token[:-len(compiler)] == compiler:
168+
if token[-len(compiler):] == compiler:
169169
print(f'Detected compiler: {token}')
170170
return token
171171

0 commit comments

Comments
 (0)