Skip to content

[4.7.7] Fix compiler warnings - #33500

Open
Jojo-Schmitz wants to merge 6 commits into
musescore:4.7from
Jojo-Schmitz:4.7-compiler-warnings
Open

Jojo-Schmitz wants to merge 6 commits into
musescore:4.7from
Jojo-Schmitz:4.7-compiler-warnings

Conversation

@Jojo-Schmitz

@Jojo-Schmitz Jojo-Schmitz commented May 20, 2026 •

Copy link
Copy Markdown
Contributor
  • reg. (MSVC):

    • 'return': conversion from 'uint32_t' to 'uint8_t', possible loss of data (C4244)
    • 'return': conversion from 'uint32_t' to 'uint16_t', possible loss of data (C4244)
    • 'initializing': conversion from '_Ty' to '_Ty2', possible loss of data (C4244)
      Went into master (now main) via Fix MSVC Compiler warnings #32771, commit 4, on April 7.
  • and reg. (MSVC):

  • and reg. (MSVC):

    • unreachable code (C4702)
      Apparently (currently) in 4.7 only
  • and reg. (gcc):

  • and reg. (CLANG);

  • and reg. (MSVC):

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@Jojo-Schmitz Jojo-Schmitz changed the title Fix MSVC compiler warnings [4.7.2] Fix MSVC compiler warnings May 20, 2026
@Jojo-Schmitz Jojo-Schmitz changed the title [4.7.2] Fix MSVC compiler warnings [4.7.x] Fix MSVC compiler warnings May 21, 2026
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch from 6b9ef06 to 99533d4 Compare May 26, 2026 13:42
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 3 times, most recently from decc2ab to b03d04e Compare June 8, 2026 18:58
@Jojo-Schmitz

Copy link
Copy Markdown
Contributor Author

Would you mind adding this to MuseScore Studio 4.7.4 ?

@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 6 times, most recently from 53719b3 to fa59929 Compare June 29, 2026 15:34
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 3 times, most recently from 197fc16 to 5e9fe1b Compare July 3, 2026 14:37
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 2 times, most recently from 25be8de to 81ddc8c Compare July 15, 2026 08:14
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 2 times, most recently from 6548565 to 5185c9b Compare July 21, 2026 11:41
@Jojo-Schmitz Jojo-Schmitz changed the title [4.7.x] Fix MSVC compiler warnings [4.7.x] Fix compiler warnings Jul 21, 2026
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 2 times, most recently from 0f221c3 to 4cce703 Compare July 29, 2026 14:51
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 3 times, most recently from f055ff9 to ad518d3 Compare August 10, 2026 17:36
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch 2 times, most recently from 7f1e6f2 to f4986e1 Compare August 20, 2026 16:32
@Jojo-Schmitz Jojo-Schmitz changed the title [4.7.x] Fix compiler warnings [4.7.6] Fix compiler warnings Sep 8, 2026
reg.:
* 'return': conversion from 'uint32_t' to 'uint8_t', possible loss of data (C4244)
* 'return': conversion from 'uint32_t' to 'uint16_t', possible loss of data (C4244)
* 'initializing': conversion from '_Ty' to '_Ty2', possible loss of data (C4244)
reg.: '=': conversion from 'size_t' to 'int', possible loss of data (C4267)
reg.: unreachable code (C4702)
reg.: this statement may fall through [-Wimplicit-fallthrough=]
reg.: lambda capture 'this' is not used [-Wunused-lambda-capture]
reg.: declaration of 'harmony' hides previous local declaration (C4456)
@Jojo-Schmitz
Jojo-Schmitz force-pushed the 4.7-compiler-warnings branch from cf5c231 to 4afd925 Compare October 29, 2026 14:52
@Jojo-Schmitz Jojo-Schmitz changed the title [4.7.6] Fix compiler warnings [4.7.7] Fix compiler warnings Oct 29, 2026
@Jojo-Schmitz

Copy link
Copy Markdown
Contributor Author

@coderabbitai: full review

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

@Jojo-Schmitz I will review all changes in this PR again.

✅ Action performed

Full review finished.

@coderabbitai

coderabbitai Bot commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
Commits

Reviewing files that changed from the base of the PR and between 96480d5 and 4afd925.

Files selected for processing: 6
  • src/engraving/editing/edit.cpp
  • src/engraving/rendering/score/tdraw.cpp
  • src/framework/midi/midievent.h
  • src/importexport/mei/internal/meiimporter.h
  • src/importexport/musicxml/internal/import/importmusicxmlpass2.cpp
  • src/musesounds/internal/musesamplercheckstatusservice.cpp

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

Walkthrough

The changes update parenthesis deletion and macOS text drawing in engraving. They adjust MIDI value conversions, change the MEI track field type, rename a local variable in MusicXML import, and remove a capture from a MuseSounds completion callback.

Priority: Low

Merge Risk: Minimal · up to 4afd9

The warning fixes are mergeable with no identified functional or operational risk.

Pre-merge checks: Passed 3 · Failed 2

Failed Failed checks: 2 warnings

Check name Status Explanation Resolution
Description check Warning The description explains the compiler warnings and references related issues, but it does not follow the required template. It omits the Resolves issue line and all required checklist items, including… Add the required template sections. Provide the resolved issue number or link, complete every applicable checklist item, and document unit-test or AI-assistance details when applicable.
Docstring Coverage Warning Docstring coverage is 28.57% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 3 passed
Check name Status Explanation
Title check Passed The title clearly identifies the primary change: fixing compiler warnings in the 4.7.7 branch.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description explains the compiler warnings and references related issues, but it does not follow the required template. It omits the Resolves issue line and all required checklist items, including the CLA, coding rules, testing, unnecessary changes, commit messages, prior attempts, and applicable unit-test or AI-assistance declarations.

Resolution

Add the required template sections. Provide the resolved issue number or link, complete every applicable checklist item, and document unit-test or AI-assistance details when applicable.

Full details: Docstring Coverage

Explanation

Docstring coverage is 28.57% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 7 functions across 6 files.

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

This branch has not been deployed

No deployments
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