Skip to content

Commit b4204ed

Browse files
authored
Clean up unused Deletion flag (facebook#24992)
This was replaced by the ChildDeletion flag when we refactored the commit phase.
1 parent e193be8 commit b4204ed

File tree

1 file changed

+27
-28
lines changed

1 file changed

+27
-28
lines changed

packages/react-reconciler/src/ReactFiberFlags.js

+27-28
Original file line numberDiff line numberDiff line change
@@ -12,53 +12,52 @@ import {enableCreateEventHandleAPI} from 'shared/ReactFeatureFlags';
1212
export type Flags = number;
1313

1414
// Don't change these two values. They're used by React Dev Tools.
15-
export const NoFlags = /* */ 0b00000000000000000000000000;
16-
export const PerformedWork = /* */ 0b00000000000000000000000001;
15+
export const NoFlags = /* */ 0b0000000000000000000000000;
16+
export const PerformedWork = /* */ 0b0000000000000000000000001;
1717

1818
// You can change the rest (and add more).
19-
export const Placement = /* */ 0b00000000000000000000000010;
20-
export const Update = /* */ 0b00000000000000000000000100;
21-
export const Deletion = /* */ 0b00000000000000000000001000;
22-
export const ChildDeletion = /* */ 0b00000000000000000000010000;
23-
export const ContentReset = /* */ 0b00000000000000000000100000;
24-
export const Callback = /* */ 0b00000000000000000001000000;
25-
export const DidCapture = /* */ 0b00000000000000000010000000;
26-
export const ForceClientRender = /* */ 0b00000000000000000100000000;
27-
export const Ref = /* */ 0b00000000000000001000000000;
28-
export const Snapshot = /* */ 0b00000000000000010000000000;
29-
export const Passive = /* */ 0b00000000000000100000000000;
30-
export const Hydrating = /* */ 0b00000000000001000000000000;
31-
export const Visibility = /* */ 0b00000000000010000000000000;
32-
export const StoreConsistency = /* */ 0b00000000000100000000000000;
19+
export const Placement = /* */ 0b0000000000000000000000010;
20+
export const Update = /* */ 0b0000000000000000000000100;
21+
export const ChildDeletion = /* */ 0b0000000000000000000001000;
22+
export const ContentReset = /* */ 0b0000000000000000000010000;
23+
export const Callback = /* */ 0b0000000000000000000100000;
24+
export const DidCapture = /* */ 0b0000000000000000001000000;
25+
export const ForceClientRender = /* */ 0b0000000000000000010000000;
26+
export const Ref = /* */ 0b0000000000000000100000000;
27+
export const Snapshot = /* */ 0b0000000000000001000000000;
28+
export const Passive = /* */ 0b0000000000000010000000000;
29+
export const Hydrating = /* */ 0b0000000000000100000000000;
30+
export const Visibility = /* */ 0b0000000000001000000000000;
31+
export const StoreConsistency = /* */ 0b0000000000010000000000000;
3332

3433
export const LifecycleEffectMask =
3534
Passive | Update | Callback | Ref | Snapshot | StoreConsistency;
3635

3736
// Union of all commit flags (flags with the lifetime of a particular commit)
38-
export const HostEffectMask = /* */ 0b00000000000111111111111111;
37+
export const HostEffectMask = /* */ 0b0000000000011111111111111;
3938

4039
// These are not really side effects, but we still reuse this field.
41-
export const Incomplete = /* */ 0b00000000001000000000000000;
42-
export const ShouldCapture = /* */ 0b00000000010000000000000000;
43-
export const ForceUpdateForLegacySuspense = /* */ 0b00000000100000000000000000;
44-
export const DidPropagateContext = /* */ 0b00000001000000000000000000;
45-
export const NeedsPropagation = /* */ 0b00000010000000000000000000;
46-
export const Forked = /* */ 0b00000100000000000000000000;
40+
export const Incomplete = /* */ 0b0000000000100000000000000;
41+
export const ShouldCapture = /* */ 0b0000000001000000000000000;
42+
export const ForceUpdateForLegacySuspense = /* */ 0b0000000010000000000000000;
43+
export const DidPropagateContext = /* */ 0b0000000100000000000000000;
44+
export const NeedsPropagation = /* */ 0b0000001000000000000000000;
45+
export const Forked = /* */ 0b0000010000000000000000000;
4746

4847
// Static tags describe aspects of a fiber that are not specific to a render,
4948
// e.g. a fiber uses a passive effect (even if there are no updates on this particular render).
5049
// This enables us to defer more work in the unmount case,
5150
// since we can defer traversing the tree during layout to look for Passive effects,
5251
// and instead rely on the static flag as a signal that there may be cleanup work.
53-
export const RefStatic = /* */ 0b00001000000000000000000000;
54-
export const LayoutStatic = /* */ 0b00010000000000000000000000;
55-
export const PassiveStatic = /* */ 0b00100000000000000000000000;
52+
export const RefStatic = /* */ 0b0000100000000000000000000;
53+
export const LayoutStatic = /* */ 0b0001000000000000000000000;
54+
export const PassiveStatic = /* */ 0b0010000000000000000000000;
5655

5756
// These flags allow us to traverse to fibers that have effects on mount
5857
// without traversing the entire tree after every commit for
5958
// double invoking
60-
export const MountLayoutDev = /* */ 0b01000000000000000000000000;
61-
export const MountPassiveDev = /* */ 0b10000000000000000000000000;
59+
export const MountLayoutDev = /* */ 0b0100000000000000000000000;
60+
export const MountPassiveDev = /* */ 0b1000000000000000000000000;
6261

6362
// Groups of flags that are used in the commit phase to skip over trees that
6463
// don't contain effects, by checking subtreeFlags.

0 commit comments

Comments
 (0)