forked from OSchip/llvm-project
5f07f443be
Summary: This fixes the missing space before the designated initializer when `Cpp11BracedListStyle=false` : const struct A a = { .a = 1, .b = 2 }; ^ Also, wrapping between opening brace and designated array initializers used to have an excessive penalty (like breaking between an expression and the subscript operator), leading to unexpected wrapping: const struct Aaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaa = {[1] = aaaaaaaaaaaaaaaaaaaaaaaaaaa, [2] = bbbbbbbbbbbbbbbbbbbbbbbbbbb}; instead of: const struct Aaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaa = { [1] = aaaaaaaaaaaaaaaaaaaaaaaaaaa, [2] = bbbbbbbbbbbbbbbbbbbbbbbbbbb}; Finally, designated array initializers are not binpacked, just like designated member initializers. Reviewers: djasper Reviewed By: djasper Subscribers: cfe-commits, krasimir, klimek Differential Revision: https://reviews.llvm.org/D33491 llvm-svn: 305696 |
||
---|---|---|
.. | ||
ARCMigrate | ||
AST | ||
ASTMatchers | ||
Analysis | ||
Basic | ||
CodeGen | ||
Driver | ||
Edit | ||
Format | ||
Frontend | ||
FrontendTool | ||
Headers | ||
Index | ||
Lex | ||
Parse | ||
Rewrite | ||
Sema | ||
Serialization | ||
StaticAnalyzer | ||
Tooling | ||
CMakeLists.txt |