<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - clang-format problem with AlignConsecutiveAssignments"
href="https://bugs.llvm.org/show_bug.cgi?id=33956">33956</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>clang-format problem with AlignConsecutiveAssignments
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Formatter
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>stayprivate@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>djasper@google.com, klimek@google.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=18852" name="attach_18852" title="source file">attachment 18852</a> <a href="attachment.cgi?id=18852&action=edit" title="source file">[details]</a></span>
source file
Version: clang-format version 6.0.0 (trunk 309066)
Installer : None ran from build/bin directory
Command line: ./clang-format input.cpp >output.cpp
Attached : input.cpp
Attached : output.cpp what I get, meant to be view with editor set with tab of
4
Attached : .clang-format file which I renamed dot.clang-format in case bugzilla
has issue with file starting with .
AlignConsecutiveAssignments is set to true but the resulting alignment is not
right.
Input:
void foo()
{
int msgxType, msgxBuffer, msgxLenBuffer, msgxCommand;
msgxType = 0;
msgxBuffer = 0;
msgxLenBuffer = 0;
msgxCommand = 0;
}
Output: However here i replaced the tabs with spaces.
void foo()
{
int msgxType, msgxBuffer, msgxLenBuffer, msgxCommand;
msgxType = 0;
msgxBuffer = 0;
msgxLenBuffer = 0;
msgxCommand = 0;
}
The = 0 for msgxBuffer is not aligned properly</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>