Skip to content

Commit ffab8e3

Browse files
zertoshfacebook-github-bot
authored andcommitted
Apply clang-format
Reviewed By: igorsugak Differential Revision: D28477074 fbshipit-source-id: f15dfc45b9fb30c661ebe2899cd882676d0fdf2a
1 parent a657c26 commit ffab8e3

File tree

4 files changed

+26
-28
lines changed

4 files changed

+26
-28
lines changed

React/Base/RCTAssert.h

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,17 @@ RCT_EXTERN BOOL RCTIsMainQueue(void);
2020
* assert handler through `RCTSetAssertFunction`.
2121
*/
2222
#ifndef NS_BLOCK_ASSERTIONS
23-
#define RCTAssert(condition, ...) \
24-
do { \
25-
if ((condition) == 0) { \
26-
_RCTAssertFormat(#condition, __FILE__, __LINE__, __func__, __VA_ARGS__); \
27-
if (RCT_NSASSERT) { \
28-
[[NSAssertionHandler currentHandler] handleFailureInFunction:(NSString * _Nonnull) @(__func__) \
29-
file:(NSString * _Nonnull) @(__FILE__) \
30-
lineNumber:__LINE__ \
31-
description:__VA_ARGS__]; \
32-
} \
33-
} \
23+
#define RCTAssert(condition, ...) \
24+
do { \
25+
if ((condition) == 0) { \
26+
_RCTAssertFormat(#condition, __FILE__, __LINE__, __func__, __VA_ARGS__); \
27+
if (RCT_NSASSERT) { \
28+
[[NSAssertionHandler currentHandler] handleFailureInFunction:(NSString *_Nonnull)@(__func__) \
29+
file:(NSString *_Nonnull)@(__FILE__) \
30+
lineNumber:__LINE__ \
31+
description:__VA_ARGS__]; \
32+
} \
33+
} \
3434
} while (false)
3535
#else
3636
#define RCTAssert(condition, ...) \

ReactAndroid/src/main/jni/first-party/yogajni/jni/YGJNIVanilla.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -726,8 +726,7 @@ static void jni_YGNodePrintJNI(JNIEnv* env, jobject obj, jlong nativePointer) {
726726
const YGNodeRef node = _jlong2YGNodeRef(nativePointer);
727727
YGNodePrint(
728728
node,
729-
(YGPrintOptions)(
730-
YGPrintOptionsStyle | YGPrintOptionsLayout | YGPrintOptionsChildren));
729+
(YGPrintOptions) (YGPrintOptionsStyle | YGPrintOptionsLayout | YGPrintOptionsChildren));
731730
#endif
732731
}
733732

ReactCommon/react/renderer/core/tests/RawPropsTest.cpp

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -191,9 +191,10 @@ TEST(RawPropsTest, handleRawPropsSingleIntGetManyTimes) {
191191
}
192192

193193
TEST(RawPropsTest, handleRawPropsPrimitiveTypes) {
194-
const auto &raw = RawProps(folly::dynamic::object("intValue", (int)42)(
195-
"doubleValue", (double)17.42)("floatValue", (float)66.67)(
196-
"stringValue", "helloworld")("boolValue", true));
194+
const auto &raw = RawProps(
195+
folly::dynamic::object("intValue", (int)42)("doubleValue", (double)17.42)(
196+
"floatValue",
197+
(float)66.67)("stringValue", "helloworld")("boolValue", true));
197198

198199
auto parser = RawPropsParser();
199200
parser.prepare<PropsPrimitiveTypes>();
@@ -209,9 +210,10 @@ TEST(RawPropsTest, handleRawPropsPrimitiveTypes) {
209210
}
210211

211212
TEST(RawPropsTest, handleRawPropsPrimitiveTypesGetTwice) {
212-
const auto &raw = RawProps(folly::dynamic::object("intValue", (int)42)(
213-
"doubleValue", (double)17.42)("floatValue", (float)66.67)(
214-
"stringValue", "helloworld")("boolValue", true));
213+
const auto &raw = RawProps(
214+
folly::dynamic::object("intValue", (int)42)("doubleValue", (double)17.42)(
215+
"floatValue",
216+
(float)66.67)("stringValue", "helloworld")("boolValue", true));
215217

216218
auto parser = RawPropsParser();
217219
parser.prepare<PropsPrimitiveTypes>();
@@ -235,9 +237,10 @@ TEST(RawPropsTest, handleRawPropsPrimitiveTypesGetTwice) {
235237
}
236238

237239
TEST(RawPropsTest, handleRawPropsPrimitiveTypesGetOutOfOrder) {
238-
const auto &raw = RawProps(folly::dynamic::object("intValue", (int)42)(
239-
"doubleValue", (double)17.42)("floatValue", (float)66.67)(
240-
"stringValue", "helloworld")("boolValue", true));
240+
const auto &raw = RawProps(
241+
folly::dynamic::object("intValue", (int)42)("doubleValue", (double)17.42)(
242+
"floatValue",
243+
(float)66.67)("stringValue", "helloworld")("boolValue", true));
241244

242245
auto parser = RawPropsParser();
243246
parser.prepare<PropsPrimitiveTypes>();

ReactCommon/yoga/yoga/Yoga.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4194,9 +4194,7 @@ YOGA_EXPORT void YGNodeCalculateLayoutWithContext(
41944194
if (node->getConfig()->printTree) {
41954195
YGNodePrint(
41964196
node,
4197-
(YGPrintOptions)(
4198-
YGPrintOptionsLayout | YGPrintOptionsChildren |
4199-
YGPrintOptionsStyle));
4197+
(YGPrintOptions) (YGPrintOptionsLayout | YGPrintOptionsChildren | YGPrintOptionsStyle));
42004198
}
42014199
#endif
42024200
}
@@ -4256,9 +4254,7 @@ YOGA_EXPORT void YGNodeCalculateLayoutWithContext(
42564254
if (nodeWithoutLegacyFlag->getConfig()->printTree) {
42574255
YGNodePrint(
42584256
nodeWithoutLegacyFlag,
4259-
(YGPrintOptions)(
4260-
YGPrintOptionsLayout | YGPrintOptionsChildren |
4261-
YGPrintOptionsStyle));
4257+
(YGPrintOptions) (YGPrintOptionsLayout | YGPrintOptionsChildren | YGPrintOptionsStyle));
42624258
}
42634259
#endif
42644260
}

0 commit comments

Comments
 (0)