File tree 1 file changed +5
-0
lines changed
1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -615,6 +615,11 @@ def _get_files(compile_action):
615
615
616
616
# Getting the source file is a little trickier than it might seem.
617
617
618
+ is_precompiled_header = any ([arg == "-xc++-header" for arg in compile_action .arguments ])
619
+ if is_precompiled_header :
620
+ header_files = [arg for arg in compile_action .arguments if not arg .startswith ('-' ) and arg .endswith (".h" )]
621
+ return set (), set (header_files )
622
+
618
623
# First, we do the obvious thing: Filter args to those that look like source files.
619
624
source_file_candidates = [arg for arg in compile_action .arguments if not arg .startswith ('-' ) and arg .endswith (_get_files .source_extensions )]
620
625
assert source_file_candidates , f"No source files found in compile args: { compile_action .arguments } .\n Please file an issue with this information!"
You can’t perform that action at this time.
0 commit comments