[llvm-bugs] [Bug 44479] New: incorrect indentation of arguments of a function call when the function name start on the next IndentWidth.
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Jan 7 06:34:40 PST 2020
https://bugs.llvm.org/show_bug.cgi?id=44479
Bug ID: 44479
Summary: incorrect indentation of arguments of a function call
when the function name start on the next IndentWidth.
Product: clang
Version: 9.0
Hardware: PC
OS: Linux
Status: NEW
Severity: release blocker
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: alfonso at rti.com
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
neeilans at live.com, richard-llvm at metafoo.co.uk
---- INPUT -----
void normalFunctionName()
{
if (functionName(loooooooooooongParam1, loooooooooooooongParam2,
looooooooooongParam3)) {
return;
}
}
---- EXPECTED OUTPUT ----
void normalFunctionName()
{
if (functionName(
loooooooooooongParam1,
loooooooooooooongParam2,
looooooooooongParam3)) {
return;
}
}
---- CLANG-FORMAT OUTPUT---- (extra indentation on the arguments)
void normalFunctionName()
{
if (functionName(
loooooooooooongParam1,
loooooooooooooongParam2,
looooooooooongParam3)) {
return;
}
}
The result have an extra indentation on the arguments of 4 spaces. This happens
always that the name of the function call starts on the next indentation (8
spaces). The indentation should not be measure base on the function name,
should be measured starting with the <<if>> statement.
---- Related clang-format rules ----
BasedOnStyle: WebKit
ColumnLimit: 80
IndentWidth: 4
ContinuationIndentWidth: 8
AlignAfterOpenBracket: AlwaysBreak
AllowAllParametersOfDeclarationOnNextLine: false
AllowAllArgumentsOnNextLine: false
AlwaysBreakAfterReturnType: None
BinPackParameters: false
BinPackArguments: false
ExperimentalAutoDetectBinPacking: false
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200107/e2abfa01/attachment-0001.html>
More information about the llvm-bugs
mailing list