Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add YGErrata Enum #37076

Closed
wants to merge 1 commit into from
Closed

Conversation

NickGerleman
Copy link
Contributor

Summary:
This adds a YGErrata bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of YGExperimentalFeature values that belong here, but keeping the current options means that the default YGErrataNone corresponds to existing default behavior, letting us stage the series of changes as:

  1. Implement errata API
  2. Update internal Yoga users we want to de-risk to YGErrataClassic or YGErrataAll (if setting UseLegacyStretchBehaviour)
  3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Differential Revision: D45254098

@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner fb-exported labels Apr 25, 2023
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

@analysis-bot
Copy link

analysis-bot commented Apr 25, 2023

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 8,623,476 -26
android hermes armeabi-v7a 7,936,357 +17
android hermes x86 9,110,436 -10
android hermes x86_64 8,965,258 +8
android jsc arm64-v8a 9,187,521 -17
android jsc armeabi-v7a 8,377,854 +20
android jsc x86 9,245,841 -3
android jsc x86_64 9,504,298 +8

Base commit: 33ebb5d
Branch: main

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 5736fe13337e737f0c0ffa59349520f7eedd5fd1
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 6a3c872bd5f17c67119849f98e83a399ceb8f5a9
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 366f7d7413150b8dccabb7f7b62be21e5b2dfd31
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 4a766025e85f8da28006864e624e60bbe377a5c0
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 1bc37dfb464dfe0c6eba366e3dabbf62bc4e2315
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: d0721f8150891ed541bd2fe06f1c0ce17adda100
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 287b12f8df38e0735dea102b3437ab89cbca3d22
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 869cafce77517f07b8e4d6a5eddc50fcc1418203
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 8c434eef4398982f142abd35ac8c580ec0992d7a
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 13da0d1251d5b9ccd01c0723dc122d051cf29d18
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

1 similar comment
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 25, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 27552632fbadc5ebf7f8b731b1c1cf98ed9f472d
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 25, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 25b3f66364fd19413ea9c8d225f556e19c0bbd28
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 15db2a6f99359d320ddb9c6d21880cb9715cf6dc
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: c122037bae72ae4bf3c3e30e2f212aeb18368e27
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 4c013a5d9492371404e0956a8fe836ec6ea9e1ba
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: cc028b878d4c24e1b58ba026d87af8f19267c51c
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 91faea8356d2ac1758ed6e23b05c45aef366debd
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: db3e496d98c610a2397ed41ded07cad72709aa23
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 462641b3d7554d617a8bb0f08febe9d033578386
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: af5881c57b634399e0cb650150072149779bbf9f
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: a3b21a5bbe727ac4842bd2a4bf88c5285803510c
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 599e99faa5399361431e131c7453f197ee8457ff
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: facebook#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: 55cf5a0e0859a4ce17e3f3a6481a0afe549b6e55
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D45254098

facebook-github-bot pushed a commit to facebook/yoga that referenced this pull request Apr 27, 2023
Summary:
Pull Request resolved: #1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in #1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: d4b61271a8018f548f2d9d8c953db4b121a502d1
@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Apr 27, 2023
@facebook-github-bot
Copy link
Contributor

This pull request has been merged in c7dcb42.

facebook-github-bot pushed a commit to facebook/litho that referenced this pull request Apr 27, 2023
Summary:
X-link: facebook/yoga#1256

X-link: facebook/react-native#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: d4b61271a8018f548f2d9d8c953db4b121a502d1
jeongshin pushed a commit to jeongshin/react-native that referenced this pull request May 7, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: d4b61271a8018f548f2d9d8c953db4b121a502d1
OlimpiaZurek pushed a commit to OlimpiaZurek/react-native that referenced this pull request May 22, 2023
Summary:
X-link: facebook/yoga#1256

Pull Request resolved: facebook#37076

This adds a `YGErrata` bitset enum matching the API and guarantees described in facebook/yoga#1247.

It is hooked up in later diffs. There are a couple of `YGExperimentalFeature` values that belong here, but keeping the current options means that the default `YGErrataNone` corresponds to existing default behavior, letting us stage the series of changes as:
1. Implement errata API
2. Update internal Yoga users we want to de-risk to `YGErrataClassic` or `YGErrataAll` (if setting `UseLegacyStretchBehaviour`)
3. Add new errata, changing Yoga defaults to be conformant, while letting internal apps opt into compatibility modes pending experimentation.

I also added a macro to let C++ users of Yoga perform bitwise operations on the enum without casting (already available for C users).

Reviewed By: rshest

Differential Revision: D45254098

fbshipit-source-id: d4b61271a8018f548f2d9d8c953db4b121a502d1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants