Skip to content

Use the standrad syntax for initiallizing structs to zero #411

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 10, 2025

Conversation

jeltz
Copy link
Collaborator

@jeltz jeltz commented Jun 10, 2025

As far as I understand you need at least one element to write a literal which initializes a struct to all zeros. In these particular cases I do not think it matters since static variables are always zero initialized but I prefer being clear.

@jeltz jeltz requested review from dutow and dAdAbird as code owners June 10, 2025 11:13
@codecov-commenter
Copy link

codecov-commenter commented Jun 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 85.51%. Comparing base (8084e6a) to head (38fd9ca).
Report is 1 commits behind head on TDE_REL_17_STABLE.

❌ Your project status has failed because the head coverage (85.51%) is below the target coverage (90.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@                Coverage Diff                 @@
##           TDE_REL_17_STABLE     #411   +/-   ##
==================================================
  Coverage              85.51%   85.51%           
==================================================
  Files                     22       22           
  Lines                   2547     2547           
  Branches                 389      389           
==================================================
  Hits                    2178     2178           
  Misses                   293      293           
  Partials                  76       76           
Components Coverage Δ
access 83.73% <ø> (ø)
catalog 88.88% <ø> (ø)
common 91.80% <ø> (ø)
encryption 72.56% <ø> (ø)
keyring 72.94% <100.00%> (ø)
src 91.42% <ø> (ø)
smgr 94.88% <ø> (ø)
transam ∅ <ø> (∅)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Collaborator

@AndersAstrand AndersAstrand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good apart from the spelling of "standard" and "initializing" in the commit message.

As far as I understand you need at least one element to write a literal
which initializes a struct to all zeros. In these particular cases I do
not think it matters since static variables are always zero initialized
but I prefer being clear.
@jeltz jeltz force-pushed the tde/struct-init branch from 1e83b4e to 38fd9ca Compare June 10, 2025 12:30
@jeltz jeltz merged commit 854e1a1 into percona:TDE_REL_17_STABLE Jun 10, 2025
16 of 17 checks passed
@jeltz jeltz deleted the tde/struct-init branch June 13, 2025 12:40
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.

3 participants