Compare commits

..

2 Commits

Author SHA1 Message Date
Sidharth Guglani
6d271c05f6 update yoga version to 1.13.0
Summary: Bump yoga version to 1.13.0

Reviewed By: davidaurelio

Differential Revision: D14300306

fbshipit-source-id: 2865462731bcea7666ea14768dd6eb1a112944a9
2019-03-04 07:42:35 -08:00
David Aurelio
a9bddf87ff Fix problems with GCC < v8
Summary:
@public

GCC up until v7 flags our way of reading edges in `YGNodeSetStyleInputs` as unused variables. I managed to work around that by rearranging the casts a bit.

Reviewed By: SidharthGuglani

Differential Revision: D14299439

fbshipit-source-id: eec0266185504d1b790b9ef574bd4a83c0059d3a
2019-03-04 02:37:17 -08:00
2 changed files with 15 additions and 18 deletions

View File

@@ -9,7 +9,7 @@
org.gradle.jvmargs=-Xmx1536M org.gradle.jvmargs=-Xmx1536M
VERSION_NAME=1.12.0-SNAPSHOT VERSION_NAME=1.13.0
POM_URL=https://github.com/facebook/yoga POM_URL=https://github.com/facebook/yoga
POM_SCM_URL=https://github.com/facebook/yoga.git POM_SCM_URL=https://github.com/facebook/yoga.git
POM_SCM_CONNECTION=scm:git:https://github.com/facebook/yoga.git POM_SCM_CONNECTION=scm:git:https://github.com/facebook/yoga.git

View File

@@ -755,18 +755,17 @@ static void YGNodeSetStyleInputs(
YGNodeStyleSetDisplay(node, static_cast<YGDisplay>(*styleInputs++)); YGNodeStyleSetDisplay(node, static_cast<YGDisplay>(*styleInputs++));
break; break;
case Margin: { case Margin: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float marginValue = *styleInputs++; float marginValue = *styleInputs++;
ygNodeRefToYGNodeContext(node)->edgeSetFlag |= MARGIN; ygNodeRefToYGNodeContext(node)->edgeSetFlag |= MARGIN;
YGNodeStyleSetMargin(node, static_cast<YGEdge>(edge), marginValue); YGNodeStyleSetMargin(node, edge, marginValue);
break; break;
} }
case MarginPercent: { case MarginPercent: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float marginPercent = *styleInputs++; float marginPercent = *styleInputs++;
ygNodeRefToYGNodeContext(node)->edgeSetFlag |= MARGIN; ygNodeRefToYGNodeContext(node)->edgeSetFlag |= MARGIN;
YGNodeStyleSetMarginPercent( YGNodeStyleSetMarginPercent(node, edge, marginPercent);
node, static_cast<YGEdge>(edge), marginPercent);
break; break;
} }
case MarginAuto: { case MarginAuto: {
@@ -775,38 +774,36 @@ static void YGNodeSetStyleInputs(
break; break;
} }
case Padding: { case Padding: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float paddingValue = *styleInputs++; float paddingValue = *styleInputs++;
ygNodeRefToYGNodeContext(node)->edgeSetFlag |= PADDING; ygNodeRefToYGNodeContext(node)->edgeSetFlag |= PADDING;
YGNodeStyleSetPadding(node, static_cast<YGEdge>(edge), paddingValue); YGNodeStyleSetPadding(node, edge, paddingValue);
break; break;
} }
case PaddingPercent: { case PaddingPercent: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float paddingPercent = *styleInputs++; float paddingPercent = *styleInputs++;
ygNodeRefToYGNodeContext(node)->edgeSetFlag |= PADDING; ygNodeRefToYGNodeContext(node)->edgeSetFlag |= PADDING;
YGNodeStyleSetPaddingPercent( YGNodeStyleSetPaddingPercent(node, edge, paddingPercent);
node, static_cast<YGEdge>(edge), paddingPercent);
break; break;
} }
case Border: { case Border: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float borderValue = *styleInputs++; float borderValue = *styleInputs++;
ygNodeRefToYGNodeContext(node)->edgeSetFlag |= BORDER; ygNodeRefToYGNodeContext(node)->edgeSetFlag |= BORDER;
YGNodeStyleSetBorder(node, static_cast<YGEdge>(edge), borderValue); YGNodeStyleSetBorder(node, edge, borderValue);
break; break;
} }
case Position: { case Position: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float positionValue = *styleInputs++; float positionValue = *styleInputs++;
YGNodeStyleSetPosition(node, static_cast<YGEdge>(edge), positionValue); YGNodeStyleSetPosition(node, edge, positionValue);
break; break;
} }
case PositionPercent: { case PositionPercent: {
float edge = *styleInputs++; auto edge = static_cast<YGEdge>(*styleInputs++);
float positionPercent = *styleInputs++; float positionPercent = *styleInputs++;
YGNodeStyleSetPositionPercent( YGNodeStyleSetPositionPercent(node, edge, positionPercent);
node, static_cast<YGEdge>(edge), positionPercent);
break; break;
} }
case IsReferenceBaseline: { case IsReferenceBaseline: {