Reland "Replace param |disposition| with |should_report| on IsFeatureEnabled"
This reverts commit df399aaa. Reason for revert: The dependency CL got reverted. Reland after the dependency CL is relanded. Original change's description: > Revert "Replace param |disposition| with |should_report| on IsFeatureEnabled" > > This reverts commit ccf8b883. > > Reason for revert: To revert https://chromium-review.googlesource.com/c/chromium/src/+/2028666 > > https://chromium-review.googlesource.com/c/chromium/src/+/2028666 seems to cause LinuxCFI tests failures. > > LinuxCFI tests start failing at > https://ci.chromium.org/p/chromium/builders/ci/Linux%20CFI/16433 > 16433 contains https://chromium-review.googlesource.com/c/chromium/src/+/2028666 > > Original change's description: > > Replace param |disposition| with |should_report| on IsFeatureEnabled > > > > Previously |disposition| on IsFeatureEnabled have an awkward type > > base::Optional<mojom::FeaturePolicyDisposition>*, which has 3 states > > correspond to FeatureEnabledState: > > - base::nullopt <= kEnabled > > - FeaturePolicyDisposition::kReport <= kReportOnly > > - FeaturePolicyDisposition::kEnforce <= kDisabled > > > > This CL simplifies the representation of this piece of information to > > |should_report|, and removes FeatureEnabledState enum. > > > > The mapping of FeatureEnabledState to new logic: > > kEnabled: enabled=true; should_report=false > > kReportOnly: enabled = true; should_report=true > > kDisabled: enabled = false; should_report=true > > > > Change-Id: I1fa82fb5e9924b8eed448853b139772e024bd531 > > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2037326 > > > Change-Id: Id6531935bbc777662fc3af2af65612495cb5a803 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2059555 # Not skipping CQ checks because original CL landed > 1 day ago. Change-Id: I016c9280e74db35d35d04dcbcf4dfe93ee022836 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2061397 Commit-Queue: Charlie Hu <chenleihu@google.com> Reviewed-by:Daniel Cheng <dcheng@chromium.org> Reviewed-by:
Ian Clelland <iclelland@chromium.org> Cr-Commit-Position: refs/heads/master@{#743137}
Showing
Please register or sign in to comment