Skip to content

Fix member initialization order to match declaration order#167

Open
HFTrader wants to merge 1 commit intoefficient:masterfrom
HFTrader:fix-member-init-order
Open

Fix member initialization order to match declaration order#167
HFTrader wants to merge 1 commit intoefficient:masterfrom
HFTrader:fix-member-init-order

Conversation

@HFTrader
Copy link
Copy Markdown

Summary

  • Reorder the member initializer lists in all three non-default constructors to match the member declaration order
  • C++ initializes members in declaration order regardless of init-list order, so the previous ordering triggered -Wreorder warnings on every template instantiation (~90 warnings with -Wall)
  • The actual initialization values are unchanged — this is purely a cosmetic fix to silence compiler diagnostics

Test plan

  • All existing unit tests pass
  • Verified zero -Wreorder warnings with -Wall -Wextra -Wpedantic
  • No functional change — initialization values identical before and after

Reorder the member initializer lists in all three non-default
constructors to match the member declaration order. C++ initializes
members in declaration order regardless of init-list order, so the
previous ordering triggered -Wreorder warnings on every template
instantiation (~90 warnings with -Wall).

The actual initialization values are unchanged — this is purely
a cosmetic fix to silence compiler diagnostics.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant