refactor: inline constant `f_obfuscate = false` parameter #34048

pull l0rinc wants to merge 1 commits into bitcoin:master from l0rinc:l0rinc/inline-constant-obfuscate-param changing 2 files +3 −4
  1. l0rinc commented at 10:26 PM on December 10, 2025: contributor

    Split out of #33324 since it makes sense on its own.

    Currently the parameter is only called with a single constant parameter, it doesn't make sense to needlessly obfuscate the constructor (pun intended).

  2. refactor: inline constant `f_obfuscate = false` parameter 1670fb14d0
  3. DrahtBot added the label Refactoring on Dec 10, 2025
  4. DrahtBot commented at 10:26 PM on December 10, 2025: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/34048.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline for information on the review process. A summary of reviews will appear here.

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    No conflicts as of last run.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  5. in src/index/base.h:68 in 1670fb14d0
      63 | @@ -64,8 +64,7 @@ class BaseIndex : public CValidationInterface
      64 |      class DB : public CDBWrapper
      65 |      {
      66 |      public:
      67 | -        DB(const fs::path& path, size_t n_cache_size,
      68 | -           bool f_memory = false, bool f_wipe = false, bool f_obfuscate = false);
    


    maflcko commented at 8:10 AM on December 11, 2025:

    i presume this exists to allow indexes to obfuscate, if there is need to? E.g. when storing remote-user-provided data. E.g. an addrindex?

    I understand this isn't needed right now, so no strong opinion.


    l0rinc commented at 12:49 PM on December 11, 2025:

    Yes, it's an unused argument - it's clearer to remove the fake single-instance-abstraction

  6. Ataraxia009 commented at 9:09 AM on December 11, 2025: none

    Concept NAck, could be needed in the future, no point in hiding it

  7. l0rinc commented at 10:31 AM on December 11, 2025: contributor

    if it's needed in the future, it's trivial to reintroduce it.

  8. Ataraxia009 commented at 5:52 AM on December 12, 2025: none

    if it's needed in the future, it's trivial to reintroduce it.

    It seems like a strong enough option to leave as is still but ill defer to others i dont have a strong opinion

  9. l0rinc commented at 10:23 PM on December 18, 2025: contributor

    Closing for lack of interest, will keep it in the original PR only

  10. l0rinc closed this on Dec 18, 2025


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-22 06:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me