Page MenuHomePhabricator

[DOC] Add headers inclusion guidelines to the developer notes
ClosedPublic

Authored by Fabien on Apr 25 2019, 16:26.

Details

Summary

Extracted from the recent changes to the header inclusions.

Test Plan
Read it.

Diff Detail

Repository
rABC Bitcoin ABC
Branch
doc_header_ordering
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 5601
Build 9264: Bitcoin ABC Buildbot (legacy)
Build 9263: arc lint + arc unit

Event Timeline

jasonbcox requested changes to this revision.Apr 25 2019, 16:43
jasonbcox added a subscriber: jasonbcox.
jasonbcox added inline comments.
doc/developer-notes.md
501 ↗(On Diff #8272)

My suggested addition at the end:

- In order to make the code consistent, header files should be included in the following order, with each section separated by a newline:
502 ↗(On Diff #8272)

block -> section (just because block is so heavily used in other contexts :P)

503 ↗(On Diff #8272)

for -> from

506 ↗(On Diff #8272)

Should we mention anything about internal 3rd party dependencies (ie: univalue) and external (ie: boost)? I've always imagined that internal dependencies should always come before external, though I admit I don't have strong reasoning for this beyond that it seems reasonable to me.

This revision now requires changes to proceed.Apr 25 2019, 16:43

Update as per feedbacks

This revision is now accepted and ready to land.Apr 25 2019, 17:37
This revision was automatically updated to reflect the committed changes.