Update clang-format to 8.0.
GitOrigin-RevId: 170be47e4b47607a2bca81d2ed6b5b3d547982ca
This commit is contained in:
parent
24a66bf9e7
commit
f5ea140bc2
@ -17,7 +17,7 @@ AllowShortLoopsOnASingleLine: false # true
|
||||
AlwaysBreakAfterDefinitionReturnType: None
|
||||
AlwaysBreakAfterReturnType: None
|
||||
AlwaysBreakBeforeMultilineStrings: true
|
||||
AlwaysBreakTemplateDeclarations: true
|
||||
AlwaysBreakTemplateDeclarations: Yes
|
||||
BinPackArguments: true
|
||||
BinPackParameters: true
|
||||
BraceWrapping:
|
||||
@ -39,6 +39,7 @@ BraceWrapping:
|
||||
BreakBeforeBinaryOperators: None
|
||||
BreakBeforeBraces: Attach
|
||||
BreakBeforeInheritanceComma: true # false
|
||||
BreakInheritanceList: BeforeComma # BeforeColon
|
||||
BreakBeforeTernaryOperators: true
|
||||
BreakConstructorInitializersBeforeComma: true # false
|
||||
BreakConstructorInitializers: BeforeComma # BeforeColon
|
||||
@ -55,7 +56,9 @@ DerivePointerAlignment: true
|
||||
DisableFormat: false
|
||||
ExperimentalAutoDetectBinPacking: false
|
||||
FixNamespaceComments: true
|
||||
ForEachMacros: [ Q_FOREACH_THIS_LIST_MUST_BE_NON_EMPTY ]
|
||||
ForEachMacros:
|
||||
- Q_FOREACH_THIS_LIST_MUST_BE_NON_EMPTY
|
||||
IncludeBlocks: Preserve
|
||||
IndentCaseLabels: true
|
||||
IndentPPDirectives: None
|
||||
IndentWidth: 2
|
||||
@ -67,14 +70,16 @@ MacroBlockBegin: ''
|
||||
MacroBlockEnd: ''
|
||||
MaxEmptyLinesToKeep: 1
|
||||
NamespaceIndentation: None
|
||||
# ObjCBinPackProtocolList: Never
|
||||
# ObjCBlockIndentWidth: 2
|
||||
# ObjCSpaceAfterProperty: false
|
||||
# ObjCSpaceBeforeProtocolList: false
|
||||
# ObjCSpaceBeforeProtocolList: true
|
||||
PenaltyBreakAssignment: 2
|
||||
PenaltyBreakBeforeFirstCallParameter: 1
|
||||
PenaltyBreakComment: 300
|
||||
PenaltyBreakFirstLessLess: 120
|
||||
PenaltyBreakString: 1000
|
||||
PenaltyBreakTemplateDeclaration: 10
|
||||
PenaltyExcessCharacter: 1000000
|
||||
PenaltyReturnTypeOnItsOwnLine: 200
|
||||
PointerAlignment: Left
|
||||
@ -84,7 +89,11 @@ SortUsingDeclarations: false # true
|
||||
SpaceAfterCStyleCast: false
|
||||
SpaceAfterTemplateKeyword: true
|
||||
SpaceBeforeAssignmentOperators: true
|
||||
SpaceBeforeCpp11BracedList: false
|
||||
SpaceBeforeCtorInitializerColon: true
|
||||
SpaceBeforeInheritanceColon: true
|
||||
SpaceBeforeParens: ControlStatements
|
||||
SpaceBeforeRangeBasedForLoopColon: true
|
||||
SpaceInEmptyParentheses: false
|
||||
SpacesBeforeTrailingComments: 2
|
||||
SpacesInAngles: false
|
||||
|
@ -15,8 +15,7 @@
|
||||
|
||||
namespace td {
|
||||
template <class BinlogT, class StorerT>
|
||||
uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &storer,
|
||||
Promise<> promise = Promise<>()) {
|
||||
uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &storer, Promise<> promise = Promise<>()) {
|
||||
auto logevent_id = binlog_ptr->next_id();
|
||||
binlog_ptr->add_raw_event(logevent_id, BinlogEvent::create_raw(logevent_id, type, 0, storer), std::move(promise));
|
||||
return logevent_id;
|
||||
@ -24,7 +23,7 @@ uint64 binlog_add(const BinlogT &binlog_ptr, int32 type, const StorerT &storer,
|
||||
|
||||
template <class BinlogT, class StorerT>
|
||||
uint64 binlog_rewrite(const BinlogT &binlog_ptr, uint64 logevent_id, int32 type, const StorerT &storer,
|
||||
Promise<> promise = Promise<>()) {
|
||||
Promise<> promise = Promise<>()) {
|
||||
auto seq_no = binlog_ptr->next_id();
|
||||
binlog_ptr->add_raw_event(seq_no, BinlogEvent::create_raw(logevent_id, type, BinlogEvent::Flags::Rewrite, storer),
|
||||
std::move(promise));
|
||||
@ -35,7 +34,7 @@ uint64 binlog_rewrite(const BinlogT &binlog_ptr, uint64 logevent_id, int32 type,
|
||||
|
||||
template <class BinlogT>
|
||||
uint64 binlog_erase_impl(BinlogDebugInfo info, const BinlogT &binlog_ptr, uint64 logevent_id,
|
||||
Promise<> promise = Promise<>()) {
|
||||
Promise<> promise = Promise<>()) {
|
||||
auto seq_no = binlog_ptr->next_id();
|
||||
binlog_ptr->add_raw_event(info, seq_no,
|
||||
BinlogEvent::create_raw(logevent_id, BinlogEvent::ServiceTypes::Empty,
|
||||
|
@ -165,8 +165,7 @@ Slice::Slice(T s, std::enable_if_t<std::is_same<char *, std::remove_const_t<T>>:
|
||||
}
|
||||
|
||||
template <class T>
|
||||
Slice::Slice(T s, std::enable_if_t<std::is_same<const char *, std::remove_const_t<T>>::value, private_tag>)
|
||||
: s_(s) {
|
||||
Slice::Slice(T s, std::enable_if_t<std::is_same<const char *, std::remove_const_t<T>>::value, private_tag>) : s_(s) {
|
||||
CHECK(s_ != nullptr);
|
||||
len_ = std::strlen(s_);
|
||||
}
|
||||
|
Reference in New Issue
Block a user