Flow upgrade to 0.205.1 (#26796)

Just a small upgrade to keep us current and remove unused suppressions
(probably fixed by some upgrade since).

- `*` is no longer allowed and has been an alias for `any` for a while
now.

DiffTrain build for [fda1f0b902](https://github.com/facebook/react/commit/fda1f0b902b527089fe5ae7b3aa573c633166ec9)
This commit is contained in:
kassens
2023-05-09 14:53:56 +00:00
parent c16551253d
commit 3df08cb0ac
21 changed files with 35 additions and 59 deletions
+1 -1
View File
@@ -1 +1 @@
b00e27342d6ff0f2a3a57b8e1edf66290d27cf07
fda1f0b902b527089fe5ae7b3aa573c633166ec9
+2 -3
View File
@@ -27,7 +27,7 @@ if (
}
"use strict";
var ReactVersion = "18.3.0-www-classic-53439320";
var ReactVersion = "18.3.0-www-classic-cb3b85f4";
// ATTENTION
// When adding new symbols to this file,
@@ -2012,8 +2012,7 @@ function useCacheRefresh() {
return dispatcher.useCacheRefresh();
}
function use(usable) {
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
var dispatcher = resolveDispatcher();
return dispatcher.use(usable);
}
function useMemoCache(size) {
+2 -3
View File
@@ -27,7 +27,7 @@ if (
}
"use strict";
var ReactVersion = "18.3.0-www-modern-171e8ddd";
var ReactVersion = "18.3.0-www-modern-bc9d666a";
// ATTENTION
// When adding new symbols to this file,
@@ -2012,8 +2012,7 @@ function useCacheRefresh() {
return dispatcher.useCacheRefresh();
}
function use(usable) {
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
var dispatcher = resolveDispatcher();
return dispatcher.use(usable);
}
function useMemoCache(size) {
@@ -69,7 +69,7 @@ function _assertThisInitialized(self) {
return self;
}
var ReactVersion = "18.3.0-www-classic-e737edcf";
var ReactVersion = "18.3.0-www-classic-e1e0fe51";
var LegacyRoot = 0;
var ConcurrentRoot = 1;
@@ -4794,7 +4794,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
+2 -2
View File
@@ -69,7 +69,7 @@ function _assertThisInitialized(self) {
return self;
}
var ReactVersion = "18.3.0-www-modern-2d91b5df";
var ReactVersion = "18.3.0-www-modern-f0df93d6";
var LegacyRoot = 0;
var ConcurrentRoot = 1;
@@ -4550,7 +4550,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -10193,7 +10193,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "18.3.0-www-classic-64ad8763",
version: "18.3.0-www-classic-b2a7bab7",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1325 = {
@@ -10224,7 +10224,7 @@ var internals$jscomp$inline_1325 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-64ad8763"
reconcilerVersion: "18.3.0-www-classic-b2a7bab7"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1326 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -9858,7 +9858,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "18.3.0-www-modern-a1c71e8e",
version: "18.3.0-www-modern-50ab1d1d",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1305 = {
@@ -9889,7 +9889,7 @@ var internals$jscomp$inline_1305 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-a1c71e8e"
reconcilerVersion: "18.3.0-www-modern-50ab1d1d"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1306 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -9420,7 +9420,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -34168,7 +34168,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-0991f810";
var ReactVersion = "18.3.0-www-classic-b6d18d0e";
function createPortal$1(
children,
@@ -37893,7 +37893,6 @@ function addTrappedEventListener(
if (enableLegacyFBSupport && isDeferredListenerForLegacyFBSupport) {
var originalListener = listener; // $FlowFixMe[missing-this-annot]
// $FlowFixMe[definition-cycle]
listener = function () {
removeEventListener(targetContainer, domEventName, unsubscribeListener);
+2 -3
View File
@@ -9361,7 +9361,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -34013,7 +34013,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-a1c71e8e";
var ReactVersion = "18.3.0-www-modern-50ab1d1d";
function createPortal$1(
children,
@@ -38401,7 +38401,6 @@ function addTrappedEventListener(
if (enableLegacyFBSupport && isDeferredListenerForLegacyFBSupport) {
var originalListener = listener; // $FlowFixMe[missing-this-annot]
// $FlowFixMe[definition-cycle]
listener = function () {
removeEventListener(
@@ -9554,7 +9554,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -34785,7 +34785,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-f2874d23";
var ReactVersion = "18.3.0-www-classic-cc8acd04";
function createPortal$1(
children,
@@ -38510,7 +38510,6 @@ function addTrappedEventListener(
if (enableLegacyFBSupport && isDeferredListenerForLegacyFBSupport) {
var originalListener = listener; // $FlowFixMe[missing-this-annot]
// $FlowFixMe[definition-cycle]
listener = function () {
removeEventListener(targetContainer, domEventName, unsubscribeListener);
@@ -9495,7 +9495,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -34630,7 +34630,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-647efb04";
var ReactVersion = "18.3.0-www-modern-b5e9f35e";
function createPortal$1(
children,
@@ -39018,7 +39018,6 @@ function addTrappedEventListener(
if (enableLegacyFBSupport && isDeferredListenerForLegacyFBSupport) {
var originalListener = listener; // $FlowFixMe[missing-this-annot]
// $FlowFixMe[definition-cycle]
listener = function () {
removeEventListener(
@@ -16971,7 +16971,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1858 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-classic-e737edcf",
version: "18.3.0-www-classic-e1e0fe51",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2237 = {
@@ -17001,7 +17001,7 @@ var internals$jscomp$inline_2237 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-classic-e737edcf"
reconcilerVersion: "18.3.0-www-classic-e1e0fe51"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2238 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -17395,4 +17395,4 @@ exports.unstable_renderSubtreeIntoContainer = function (
);
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-classic-e737edcf";
exports.version = "18.3.0-www-classic-e1e0fe51";
@@ -16553,7 +16553,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1817 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "18.3.0-www-modern-171e8ddd",
version: "18.3.0-www-modern-bc9d666a",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2201 = {
@@ -16584,7 +16584,7 @@ var internals$jscomp$inline_2201 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "18.3.0-www-modern-171e8ddd"
reconcilerVersion: "18.3.0-www-modern-bc9d666a"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2202 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -16906,4 +16906,4 @@ exports.unstable_createEventHandle = function (type, options) {
return eventHandle;
};
exports.unstable_runWithPriority = runWithPriority;
exports.version = "18.3.0-www-modern-171e8ddd";
exports.version = "18.3.0-www-modern-bc9d666a";
@@ -365,7 +365,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
if (typeof value === "string") {
substr = value;
} else if (typeof value === "object" && value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
substr = "{" + describeObjectForErrorMessage(value) + "}";
} else {
substr = "{" + describeValueForErrorMessage(value) + "}";
@@ -398,7 +397,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr = void 0;
if (typeof _value === "object" && _value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr = describeObjectForErrorMessage(_value);
} else {
_substr = describeValueForErrorMessage(_value);
@@ -441,7 +439,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
typeof _value2 === "object" &&
_value2 !== null
) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr2 = describeObjectForErrorMessage(_value2);
} else {
_substr2 = describeValueForErrorMessage(_value2);
@@ -482,7 +479,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr3 = void 0;
if (typeof _value3 === "object" && _value3 !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr3 = describeObjectForErrorMessage(_value3);
} else {
_substr3 = describeValueForErrorMessage(_value3);
@@ -735,7 +731,7 @@ function processReply(root, formFieldPrefix, resolve, reject) {
if (value[value.length - 1] === "Z") {
// Possibly a Date, whose toJSON automatically calls toISOString
// $FlowFixMe[incompatible-use]
var _originalValue = parent[key]; // $FlowFixMe[method-unbinding]
var _originalValue = parent[key];
if (_originalValue instanceof Date) {
return serializeDateFromDateJSON(value);
@@ -365,7 +365,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
if (typeof value === "string") {
substr = value;
} else if (typeof value === "object" && value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
substr = "{" + describeObjectForErrorMessage(value) + "}";
} else {
substr = "{" + describeValueForErrorMessage(value) + "}";
@@ -398,7 +397,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr = void 0;
if (typeof _value === "object" && _value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr = describeObjectForErrorMessage(_value);
} else {
_substr = describeValueForErrorMessage(_value);
@@ -441,7 +439,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
typeof _value2 === "object" &&
_value2 !== null
) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr2 = describeObjectForErrorMessage(_value2);
} else {
_substr2 = describeValueForErrorMessage(_value2);
@@ -482,7 +479,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr3 = void 0;
if (typeof _value3 === "object" && _value3 !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr3 = describeObjectForErrorMessage(_value3);
} else {
_substr3 = describeValueForErrorMessage(_value3);
@@ -735,7 +731,7 @@ function processReply(root, formFieldPrefix, resolve, reject) {
if (value[value.length - 1] === "Z") {
// Possibly a Date, whose toJSON automatically calls toISOString
// $FlowFixMe[incompatible-use]
var _originalValue = parent[key]; // $FlowFixMe[method-unbinding]
var _originalValue = parent[key];
if (_originalValue instanceof Date) {
return serializeDateFromDateJSON(value);
@@ -987,7 +987,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
if (typeof value === "string") {
substr = value;
} else if (typeof value === "object" && value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
substr = "{" + describeObjectForErrorMessage(value) + "}";
} else {
substr = "{" + describeValueForErrorMessage(value) + "}";
@@ -1020,7 +1019,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr = void 0;
if (typeof _value === "object" && _value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr = describeObjectForErrorMessage(_value);
} else {
_substr = describeValueForErrorMessage(_value);
@@ -1063,7 +1061,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
typeof _value2 === "object" &&
_value2 !== null
) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr2 = describeObjectForErrorMessage(_value2);
} else {
_substr2 = describeValueForErrorMessage(_value2);
@@ -1104,7 +1101,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr3 = void 0;
if (typeof _value3 === "object" && _value3 !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr3 = describeObjectForErrorMessage(_value3);
} else {
_substr3 = describeValueForErrorMessage(_value3);
@@ -1904,7 +1900,7 @@ function resolveModelToJSON(request, parent, key, value) {
if (value[value.length - 1] === "Z") {
// Possibly a Date, whose toJSON automatically calls toISOString
// $FlowFixMe[incompatible-use]
var _originalValue = parent[key]; // $FlowFixMe[method-unbinding]
var _originalValue = parent[key];
if (_originalValue instanceof Date) {
return serializeDateFromDateJSON(value);
@@ -987,7 +987,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
if (typeof value === "string") {
substr = value;
} else if (typeof value === "object" && value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
substr = "{" + describeObjectForErrorMessage(value) + "}";
} else {
substr = "{" + describeValueForErrorMessage(value) + "}";
@@ -1020,7 +1019,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr = void 0;
if (typeof _value === "object" && _value !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr = describeObjectForErrorMessage(_value);
} else {
_substr = describeValueForErrorMessage(_value);
@@ -1063,7 +1061,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
typeof _value2 === "object" &&
_value2 !== null
) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr2 = describeObjectForErrorMessage(_value2);
} else {
_substr2 = describeValueForErrorMessage(_value2);
@@ -1104,7 +1101,6 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
var _substr3 = void 0;
if (typeof _value3 === "object" && _value3 !== null) {
// $FlowFixMe[incompatible-call] found when upgrading Flow
_substr3 = describeObjectForErrorMessage(_value3);
} else {
_substr3 = describeValueForErrorMessage(_value3);
@@ -1904,7 +1900,7 @@ function resolveModelToJSON(request, parent, key, value) {
if (value[value.length - 1] === "Z") {
// Possibly a Date, whose toJSON automatically calls toISOString
// $FlowFixMe[incompatible-use]
var _originalValue = parent[key]; // $FlowFixMe[method-unbinding]
var _originalValue = parent[key];
if (_originalValue instanceof Date) {
return serializeDateFromDateJSON(value);
@@ -576,7 +576,6 @@ function createSignatureFunctionForTransform() {
// in HOC chains like _s(hoc1(_s(hoc2(_s(actualFunction))))).
if (!savedType) {
// We're in the innermost call, so this is the actual type.
// $FlowFixMe[escaped-generic] discovered when updating Flow
savedType = type;
hasCustomHooks = typeof getCustomHooks === "function";
} // Set the signature for all types (even wrappers!) in case
@@ -576,7 +576,6 @@ function createSignatureFunctionForTransform() {
// in HOC chains like _s(hoc1(_s(hoc2(_s(actualFunction))))).
if (!savedType) {
// We're in the innermost call, so this is the actual type.
// $FlowFixMe[escaped-generic] discovered when updating Flow
savedType = type;
hasCustomHooks = typeof getCustomHooks === "function";
} // Set the signature for all types (even wrappers!) in case
@@ -3756,7 +3756,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -24549,7 +24549,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-classic-6e3da9e8";
var ReactVersion = "18.3.0-www-classic-b4adcaa5";
// Might add PROFILE later.
@@ -3756,7 +3756,7 @@ function shallowEqual(objA, objB) {
var currentKey = keysA[i];
if (
!hasOwnProperty.call(objB, currentKey) ||
!hasOwnProperty.call(objB, currentKey) || // $FlowFixMe[incompatible-use] lost refinement of `objB`
!objectIs(objA[currentKey], objB[currentKey])
) {
return false;
@@ -24549,7 +24549,7 @@ function createFiberRoot(
return root;
}
var ReactVersion = "18.3.0-www-modern-171e8ddd";
var ReactVersion = "18.3.0-www-modern-bc9d666a";
// Might add PROFILE later.