Issue 55477
Summary [clang-format]: AlignArrayOfStructures does not use tabs for indentation
Labels new issue
Assignees
Reporter igagis
    # to reproduce

`.clang-format`:
```yaml
---
AlignArrayOfStructures: Right
AllowAllArgumentsOnNextLine: 'false' # try also commenting this line, it changes the result a bit, still incorrect
ContinuationIndentWidth: '1'
IndentWidth: '1'
Standard: Latest
TabWidth: '1'
UseCRLF: 'false'
UseTab: ForContinuationAndIndentation

...
```

`main.cpp`:
```cpp
void func(){
	std::vector<std::pair<int, std::string>> in = {{13, "13"},{14, "14"},{ 1,  "1"}};
}
```

run
```console
clang-format main.cpp
```

# expected result

```cpp
void func() {
	std::vector<std::pair<int, std::string>> in = {
		{13, "13"},
		{14, "14"},
		{ 1,  "1"}
	};
}
```

# actual result

```cpp
void func() {
	std::vector<std::pair<int, std::string>> in = {
		{13, "13"},
		{14, "14"},
		{ 1,  "1"}
 };
}
```
The closing `};` is indented with spaces instead of tabs.

# version

```console
$ clang-format --version
Debian clang-format version 15.0.0-++20220513071846+693758b28295-1~exp1~20220513071937.249
```
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to