'internal' loop's variable hides a function's parameter of the same name #22345

pull n0feer wants to merge 3 commits into bitcoin:master from n0feer:patch-1 changing 1 files +6 −6
  1. n0feer commented at 6:10 PM on June 26, 2021: none

    Pretty clear. Just semantic change so the code in the following section would be open to changes, and less confusing.

  2. 'internal' loop's variable hides a function's parameter of the same name 4c6fe7b709
  3. DrahtBot commented at 7:57 PM on June 26, 2021: member

    <!--e57a25ab6845829454e8d69fc972939a-->

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

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  4. DrahtBot added the label Wallet on Jun 26, 2021
  5. luke-jr commented at 12:48 AM on June 27, 2021: member

    Would prefer a new name that indicates what it actually is for

  6. n0feer commented at 6:46 AM on June 27, 2021: none

    Yeah I agree that it’s not a good name. I think it’s better to just call it boolean_value or i. Do you have any better idea @luke-jr?

  7. luke-jr commented at 3:36 PM on June 27, 2021: member

    I suggest active_internal, and while you're at it, make the inner loop active_type

  8. Rename variable to active_internal 8b0ad0374a
  9. n0feer commented at 4:07 PM on June 27, 2021: none

    @luke-jr Good idea. I renamed it. Regarding the active_type variable, should I just change bool to active_type and consider it in the if statement (line 3213)?

  10. luke-jr commented at 4:55 PM on June 27, 2021: member

    Not sure what you're asking. I was just suggesting renaming the t variable to active_type

  11. luke-jr approved
  12. luke-jr commented at 4:55 PM on June 27, 2021: member

    utACK

  13. Rename variable named 't' to 'active_type' 1f6ae9c4b7
  14. n0feer commented at 5:15 PM on June 27, 2021: none

    Ok, I renamed it as you suggested. It would be cool if you can review the code once again. thnx

  15. luke-jr approved
  16. luke-jr commented at 7:01 PM on June 27, 2021: member

    re-utACK

  17. fanquake added the label Refactoring on Jun 28, 2021
  18. fanquake added the label Waiting for author on Jun 28, 2021
  19. fanquake commented at 2:26 AM on June 28, 2021: member

    Needs commits squashed, proper commit message, PR title updated etc.

  20. S3RK commented at 6:09 AM on June 28, 2021: member

    JFYI #19651 will drop this cycle

  21. fanquake commented at 1:58 AM on June 30, 2021: member

    @n0feer thanks for the contribution here, but I'm going to close this PR in favour of #19651, as that is pretty much mergable. If you'd like to make another contribution, a good place to start is the good first issue list.

  22. fanquake closed this on Jun 30, 2021

  23. fanquake removed the label Waiting for author on Jun 30, 2021
  24. DrahtBot locked this on Aug 18, 2022

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-21 15:14 UTC

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