Moved YGFloatOptional from C struct to C++ struct
Summary: Earlier `YGfloatOptional` was plain struct with no privacy around the variables. This diff adds privacy and also enforces checks when one tries to access value of an undefined `YGFloatOptional` This diff also adds a behaviour in which when a value of an undefined YGFloatOptional is accessed, it will normally terminate(Several cleanup steps are performed). Reviewed By: emilsjolander Differential Revision: D7288555 fbshipit-source-id: f61cc92c8fd0d48d2fc1f4d0e6fcef155f19ff8a
This commit is contained in:
committed by
Facebook Github Bot
parent
ae86824636
commit
5d7b75a47a
@@ -42,11 +42,6 @@ typedef struct YGValue {
|
||||
YGUnit unit;
|
||||
} YGValue;
|
||||
|
||||
struct YGFloatOptional {
|
||||
bool isUndefined;
|
||||
float value;
|
||||
};
|
||||
|
||||
extern const YGValue YGValueUndefined;
|
||||
extern const YGValue YGValueAuto;
|
||||
|
||||
|
Reference in New Issue
Block a user