Commit cd271bb
committed
Make style lookup consistent with clang-format
The current version was only
- looking up .clang_format in the file's directory.
- using -style=file option only, causing failure if pwd != file's
directory
This commit makes the behavior fully consistent with clang-format:
- lookup .clang_format in the file's directory and recursively go up
its parent directory until found. If no style file is found, defaults
to g:clang_format#style_options1 parent d90af92 commit cd271bb
1 file changed
+14
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
148 | 158 | | |
149 | | - | |
150 | 159 | | |
151 | | - | |
| 160 | + | |
152 | 161 | | |
153 | 162 | | |
154 | 163 | | |
155 | 164 | | |
156 | | - | |
| 165 | + | |
| 166 | + | |
157 | 167 | | |
158 | 168 | | |
159 | | - | |
| 169 | + | |
160 | 170 | | |
161 | 171 | | |
162 | 172 | | |
| |||
0 commit comments