From 4804bcd594d1f47d06877eeb74043ee74ec78b8b Mon Sep 17 00:00:00 2001 From: Matthew Jarjoura Date: Fri, 16 Jun 2017 11:06:10 -0700 Subject: [PATCH] make sure YGPointValue works in Obj-C++ Summary: This is an easy diff to wrap YGPointValue() in an extern "C" block to make sure it compiles when we are using inside of Objective-C++ classes. Reviewed By: emilsjolander Differential Revision: D5242366 fbshipit-source-id: 772aaac056b3a20041926d5f35128716848a271a --- YogaKit/Source/YGLayout.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/YogaKit/Source/YGLayout.h b/YogaKit/Source/YGLayout.h index 416de203..05d54a16 100644 --- a/YogaKit/Source/YGLayout.h +++ b/YogaKit/Source/YGLayout.h @@ -10,12 +10,17 @@ #import #import #import +#import + +YG_EXTERN_C_BEGIN extern YGValue YGPointValue(CGFloat value) NS_SWIFT_UNAVAILABLE("Use the swift Int and FloatingPoint extensions instead"); extern YGValue YGPercentValue(CGFloat value) NS_SWIFT_UNAVAILABLE("Use the swift Int and FloatingPoint extensions instead"); +YG_EXTERN_C_END + typedef NS_OPTIONS(NSInteger, YGDimensionFlexibility) { YGDimensionFlexibilityFlexibleWidth = 1 << 0, YGDimensionFlexibilityFlexibleHeigth = 1 << 1,