Skip to content

Commit 968686b

Browse files
cpsauerxinzhengzhang
authored andcommitted
Switch _warn_if_file_doesnt_exist return values for clarity
1 parent 1977cec commit 968686b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

refresh.template.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,8 @@ def _warn_if_file_doesnt_exist(source_file):
107107
You can either use a refresh_compile_commands rule or the special -- syntax. Please see the README.
108108
[Supplying flags normally won't work. That just causes this tool to be built with those flags.]
109109
Continuing gracefully...""")
110-
return False
111-
return True
110+
return True
111+
return False
112112
_warn_if_file_doesnt_exist.has_logged_missing_file_error = False
113113

114114
@functools.lru_cache(maxsize=None)
@@ -594,7 +594,7 @@ def _get_files(compile_action):
594594
assert source_file.endswith(_get_files.source_extensions), f"Source file candidate, {source_file}, seems to be wrong.\nSelected from {compile_action.arguments}.\nPlease file an issue with this information!"
595595

596596
# Warn gently about missing files
597-
if not _warn_if_file_doesnt_exist(source_file):
597+
if _warn_if_file_doesnt_exist(source_file):
598598
return {source_file}, set()
599599

600600
# Note: We need to apply commands to headers and sources.

0 commit comments

Comments
 (0)