Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reuse bool box objects in UncommonField<bool>.SetValue #6528

Merged
merged 2 commits into from Jun 3, 2022

Commits on May 4, 2022

  1. Reuse bool box objects in UncommonField<bool>.SetValue

    In some scenarios, these UncommonField<bool>s end up being set very frequently, and each time the value being passed in gets boxed.  We can avoid that by caching and reusing a box for each of the only two possible values (though it looks like the default value is almost always false and so it mainly only boxes true).
    stephentoub committed May 4, 2022
    Copy the full SHA
    dc928b8 View commit details
    Browse the repository at this point in the history
  2. Use BooleanBoxes

    stephentoub committed May 4, 2022
    Copy the full SHA
    70f0b74 View commit details
    Browse the repository at this point in the history