Skip to content

Commit ef4d188

Browse files
riptlripatel-fd
authored andcommitted
Add src/.clangd
Allows devs to get started with clangd without config. /.clangd is kept in gitignore to allow devs to check in custom configs.
1 parent 3242fcf commit ef4d188

File tree

2 files changed

+26
-1
lines changed

2 files changed

+26
-1
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ perf.data.old
2020

2121
# Clangd
2222
.cache
23-
.clangd
23+
/.clangd
2424
compile_commands.json
2525

2626
# Rust

src/.clangd

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
CompileFlags:
2+
Add:
3+
- -D_XOPEN_SOURCE=700
4+
- -DFD_HAS_ALLOCA=1
5+
- -DFD_HAS_HOSTED=1
6+
- -DFD_HAS_ATOMIC=1
7+
- -DFD_HAS_DOUBLE=1
8+
- -DFD_HAS_INT128=1
9+
- -DFD_HAS_ZSTD=1
10+
- -DFD_HAS_SSE=1
11+
- -DFD_USING_CLANG=1
12+
---
13+
If:
14+
PathMatch: .*\.[hc]
15+
CompileFlags:
16+
Add:
17+
- -std=c17
18+
- -Wall
19+
- -Wextra
20+
- -Wpedantic
21+
- -Wstrict-aliasing=2
22+
- -Wconversion
23+
- -Wdouble-promotion
24+
- -Wformat-security
25+
- -Wimplicit-fallthrough

0 commit comments

Comments
 (0)