Ensure that data types are consistent #11232

pull jjz wants to merge 1 commits into bitcoin:master from jjz:master changing 1 files +5 −5
  1. jjz commented at 10:17 PM on September 4, 2017: contributor
    1. nStatus of CBlockIndex is consistent with the definition of Enum(BlockStatus)
    2. The BlockHeader is consistent with the type of variable defined in CBlockHeader
  2. fanquake added the label Refactoring on Sep 5, 2017
  3. TheBlueMatt commented at 12:25 AM on September 6, 2017: member

    utACK 400bf1d9b43b19a37a76145af5e9d479591b224f

  4. MarcoFalke commented at 12:28 AM on September 6, 2017: member

    utACK 400bf1d

  5. in src/chain.h:209 in 400bf1d9b4 outdated
     203 | @@ -204,14 +204,14 @@ class CBlockIndex
     204 |      unsigned int nChainTx;
     205 |  
     206 |      //! Verification status of this block. See enum BlockStatus
     207 | -    unsigned int nStatus;
     208 | +    uint32_t nStatus;
     209 |  
     210 |      //! block header
    


    promag commented at 12:35 AM on September 6, 2017:

    Nit, improve comment like above: See CBlockHeader.

  6. JeremyRubin commented at 12:36 AM on September 6, 2017: contributor

    utACK 400bf1d

    Maybe it makes sense to make nstatus a BlockStatus?

    Maybe it makes sense to derive them from the type (decltype(CBlockHeader().nVersion) nVersion) so that the dependency is automatically in check. Maybe this is overkill though :)

  7. promag commented at 12:37 AM on September 6, 2017: member

    utACK 400bf1d.

  8. dcousens approved
  9. practicalswift commented at 8:27 AM on September 6, 2017: contributor

    utACK 400bf1d. Nice first-time contribution!

  10. dcousens approved
  11. laanwj commented at 5:57 PM on September 6, 2017: member

    My merge tool puts the entire commit message into the title:

    • 400bf1d9b Ensure that data types are consistent 1. nStatus of CBlockIndex is consistent with the definition of Enum(BlockStatus) 2. The BlockHeader is consistent with the type of variable defined in CBlockHeader (jjz)

    I think you're missing an empty line after the title. Can you please reword your commit message to our standard format:

    <short title>
    <empty line>
    <description/body>
    ...
    
  12. laanwj assigned laanwj on Sep 6, 2017
  13. Ensure that data types are consistent
    1. nStatus of CBlockIndex  is consistent with the definition of Enum(BlockStatus)
    
    2. The BlockHeader is consistent with the type of variable defined in CBlockHeader
    061297f0ac
  14. jjz commented at 3:25 AM on September 7, 2017: contributor

    @laanwj I'm sorry for that i didn't match standard format , i've reword my commit message

  15. laanwj merged this on Sep 7, 2017
  16. laanwj closed this on Sep 7, 2017

  17. laanwj referenced this in commit 2f0d3e604a on Sep 7, 2017
  18. PastaPastaPasta referenced this in commit d186cf62b5 on Sep 23, 2019
  19. PastaPastaPasta referenced this in commit 4222898a08 on Dec 21, 2019
  20. PastaPastaPasta referenced this in commit cd589e4317 on Jan 2, 2020
  21. PastaPastaPasta referenced this in commit 18de782440 on Jan 4, 2020
  22. PastaPastaPasta referenced this in commit ed98f5f912 on Jan 4, 2020
  23. PastaPastaPasta referenced this in commit 28e48d3031 on Jan 10, 2020
  24. PastaPastaPasta referenced this in commit d0366055bb on Jan 10, 2020
  25. PastaPastaPasta referenced this in commit 84e5b323b2 on Jan 10, 2020
  26. PastaPastaPasta referenced this in commit 1a406171c6 on Jan 12, 2020
  27. ckti referenced this in commit 201398f275 on Mar 28, 2021
  28. furszy referenced this in commit 60d36292bc on Jul 26, 2021
  29. DrahtBot locked this on Sep 8, 2021

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

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