Flow: inference_mode=constrain_writes#25422
Closed
kassens wants to merge 3 commits intogh/kassens/1/basefrom
Closed
Flow: inference_mode=constrain_writes#25422kassens wants to merge 3 commits intogh/kassens/1/basefrom
kassens wants to merge 3 commits intogh/kassens/1/basefrom
Conversation
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` [ghstack-poisoned]
Closed
kassens
added a commit
to kassens/react
that referenced
this pull request
Oct 4, 2022
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` ghstack-source-id: 3372061 Pull Request resolved: facebook#25422
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` [ghstack-poisoned]
kassens
added a commit
to kassens/react
that referenced
this pull request
Oct 4, 2022
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` ghstack-source-id: a9f908c Pull Request resolved: facebook#25422
gaearon
reviewed
Oct 4, 2022
| */ | ||
|
|
||
| import * as React from 'react'; | ||
| import type { Element } from './types';import * as React from 'react'; |
gaearon
approved these changes
Oct 4, 2022
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` [ghstack-poisoned]
eps1lon
reviewed
Oct 4, 2022
| } | ||
| } | ||
| // $FlowFixMe[incompatible-type] we bail out when we get a null | ||
| node = node.return; |
Collaborator
There was a problem hiding this comment.
What was the behavior before? It looks like the FlowFixMe would now hide assignments from something that's not Fiber or null. But maybe that wasn't caught before either?
Member
Author
There was a problem hiding this comment.
I think generally a variable seems to have a more "fixed" type now. We might want to dig into the cases separetly, but I think the do { ... } while (node != null); style isn't very easy to type right.
kassens
added a commit
that referenced
this pull request
Oct 4, 2022
This mode is going to be the new default in Flow going forward. There was an unfortuante large number of suppressions in this update. More on the changes can be found in this [Flow blog post](https://medium.com/flow-type/new-flow-language-rule-constrained-writes-4c70e375d190). Added some of the required annotations using the provided codemod: ```sh node_modules/.bin/flow codemod annotate-declarations --write . ``` ghstack-source-id: 0b168e1 Pull Request resolved: #25422
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack from ghstack (oldest at bottom):
This mode is going to be the new default in Flow going forward.
There was an unfortuante large number of suppressions in this update.
More on the changes can be found in this Flow blog post.
Added some of the required annotations using the provided codemod:
node_modules/.bin/flow codemod annotate-declarations --write .