Update Flow version and fix newly reported Flow errors. (#2150)

Summary:
Release note: update Flow version

Require latest Flow version and fix newly reported type errors.
Closes https://github.com/facebook/prepack/pull/2150

Differential Revision: D8592311

Pulled By: hermanventer

fbshipit-source-id: 98b7a7de81a1aae18973ccc858cacfaa02d43f8e
This commit is contained in:
Herman Venter 2018-06-22 11:13:03 -07:00 committed by Facebook Github Bot
parent 93cd9a1d63
commit cc1e081854
3 changed files with 6 additions and 5 deletions

View File

@ -92,7 +92,7 @@
"eslint-plugin-flowtype": "^2.40.0",
"eslint-plugin-header": "^1.0.0",
"eslint-plugin-prettier": "^2.1.2",
"flow-bin": "^0.74.0",
"flow-bin": "^0.75.0",
"flow-typed": "^2.3.0",
"graceful-fs": "^4.1.11",
"invariant": "^2.2.0",

View File

@ -286,7 +286,8 @@ function parseFunctionOrderings(code: string): Array<number> {
const functionOrderPattern = /Function ordering: (\d+)/g;
let match;
while ((match = functionOrderPattern.exec(code)) != null) {
orders.push(match[1]);
invariant(match !== null);
orders.push(+match[1]);
}
return orders;
}

View File

@ -2814,9 +2814,9 @@ flat-cache@^1.2.1:
graceful-fs "^4.1.2"
write "^0.2.1"
flow-bin@^0.74.0:
version "0.74.0"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.74.0.tgz#8017bb00efb37cbe8d81fbb7f464038bde06adc9"
flow-bin@^0.75.0:
version "0.75.0"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.75.0.tgz#b96d1ee99d3b446a3226be66b4013224ce9df260"
flow-parser@^0.*:
version "0.66.0"