-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
parser: set clang -x<language> option at the low level
Have a single point of truth for setting the clang -x<language> option, to unify parsing across the extension, tests, and cli. Choose the language primarily based on the domain, and secondarily based on the filename extension to differentiate headers. Using "-header" is necessary for some cases such as "#pragma once", where plain "-xc" or "-xc++" would interpret the file as a main file. This unconditionally bypasses libclang automatic detection. The user and tests can still override the parser selected language, as the user provided clang_args are appended. Fixes: #208
- Loading branch information
Showing
3 changed files
with
21 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters