-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial support for using clangd (#375)
* Add IDE-independent `DECOMP_IDE_FLAG` define * Generate clangd config when running configure.py * Fix some errors clangd reports in RVL_SDK * Move clangd configuration flags into .clangd file * Fix clangd language cflag issues * Apply clangd compiler defines in project.py instead of .clangd * Apply a bunch of IWYU pragmas to stdlib files * Replace remaining explicit __declspecs with their macro equivalents * Fix operator new exception specifications * Couple miscellaneous fixes
- Loading branch information
1 parent
8de0975
commit f0fdd44
Showing
83 changed files
with
470 additions
and
224 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
CompileFlags: | ||
Add: [ | ||
# Remove all built-in definitions | ||
"-undef", | ||
|
||
# Indicator for things which shouldn't be processed in IDEs | ||
"-DDECOMP_IDE_FLAG", | ||
|
||
# Default to C++03 | ||
"--language=c++", | ||
"-std=c++03", | ||
|
||
# No standard includes | ||
"-nostdinc", | ||
"-nostdinc++", | ||
"-fno-builtin", | ||
|
||
# Target definitions | ||
"--target=ppc32-unknown=linux-eabi", | ||
] | ||
--- | ||
# C files | ||
If: | ||
PathMatch: .*\.c | ||
PathExclude: .*/stlport/.* # STLport is not C | ||
CompileFlags: | ||
Remove: [ | ||
"--language=", | ||
"-std=", | ||
] | ||
Add: [ | ||
"--language=c", | ||
"-std=c99", | ||
] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,10 @@ build/ | |
build.ninja | ||
objdiff.json | ||
|
||
# clangd | ||
.cache/ | ||
compile_commands.json | ||
|
||
# Doxygen output | ||
doxygen/ | ||
|
||
|
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
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#ifndef _STDARG_H_ | ||
#define _STDARG_H_ | ||
|
||
#include "MSL_Common/va_list_def.h" | ||
#include "MSL_Common/va_list_def.h" /* IWYU pragma: export */ | ||
|
||
#endif |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#ifndef _STDBOOL_H_ | ||
#define _STDBOOL_H_ | ||
|
||
#include "MSL_Common/bool_def.h" | ||
#include "MSL_Common/bool_def.h" /* IWYU pragma: export */ | ||
|
||
#endif |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
#ifndef _WCHAR_H | ||
#define _WCHAR_H | ||
|
||
#include "MSL_Common/wchar_def.h" | ||
#include "MSL_Common/wchar_io.h" | ||
#include "MSL_Common/wchar_time.h" | ||
#include "MSL_Common/wchar_sizes.h" | ||
#include "MSL_Common/wcstoul.h" | ||
#include "MSL_Common/wint_def.h" | ||
#include "MSL_Common/wmem.h" | ||
#include "MSL_Common/wprintf.h" | ||
#include "MSL_Common/wscanf.h" | ||
#include "MSL_Common/wstring.h" | ||
#include "MSL_Common/mbconvert.h" | ||
#include "MSL_Common/wchar_def.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wchar_io.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wchar_time.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wchar_sizes.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wcstoul.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wint_def.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wmem.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wprintf.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wscanf.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/wstring.h" /* IWYU pragma: export */ | ||
#include "MSL_Common/mbconvert.h" /* IWYU pragma: export */ | ||
|
||
#endif |
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
Oops, something went wrong.