Skip to content
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

LibraryScanner: static_cast<int> qsizetype values for Qt6 #4438

Merged
merged 1 commit into from
Oct 17, 2021

Conversation

Be-ing
Copy link
Contributor

@Be-ing Be-ing commented Oct 16, 2021

[356/695] Building CXX object CMakeFiles/mixxx-lib.dir/src/library/scanner/libraryscanner.cpp.o
../src/library/scanner/libraryscanner.cpp: In member function ‘void LibraryScanner::slotFinishUnhashedScan()’:
../src/library/scanner/libraryscanner.cpp:427:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  427 |            "%d unchanged directories. "
      |             ~^
      |              |
      |              int
      |             %lld
......
  432 |            m_scannerGlobal->verifiedDirectories().size(),
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                       |
      |                                                       qsizetype {aka long long int}
../src/library/scanner/libraryscanner.cpp:429:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 6 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  429 |            "%d tracks verified from changed/added directories. "
      |             ~^
      |              |
      |              int
      |             %lld
......
  434 |            m_scannerGlobal->verifiedTracks().size(),
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                  |
      |                                                  qsizetype {aka long long int}
../src/library/scanner/libraryscanner.cpp:430:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 7 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  430 |            "%d new tracks.",
      |             ~^
      |              |
      |              int
      |             %lld
......
  435 |            m_scannerGlobal->addedTracks().size());
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                               |
      |                                               qsizetype {aka long long int}

[356/695] Building CXX object CMakeFiles/mixxx-lib.dir/src/library/scanner/libraryscanner.cpp.o
../src/library/scanner/libraryscanner.cpp: In member function ‘void LibraryScanner::slotFinishUnhashedScan()’:
../src/library/scanner/libraryscanner.cpp:427:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  427 |            "%d unchanged directories. "
      |             ~^
      |              |
      |              int
      |             %lld
......
  432 |            m_scannerGlobal->verifiedDirectories().size(),
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                       |
      |                                                       qsizetype {aka long long int}
../src/library/scanner/libraryscanner.cpp:429:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 6 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  429 |            "%d tracks verified from changed/added directories. "
      |             ~^
      |              |
      |              int
      |             %lld
......
  434 |            m_scannerGlobal->verifiedTracks().size(),
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                                  |
      |                                                  qsizetype {aka long long int}
../src/library/scanner/libraryscanner.cpp:430:14: warning: format ‘%d’ expects argument of type ‘int’, but argument 7 has type ‘qsizetype’ {aka ‘long long int’} [-Wformat=]
  430 |            "%d new tracks.",
      |             ~^
      |              |
      |              int
      |             %lld
......
  435 |            m_scannerGlobal->addedTracks().size());
      |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                                               |
      |                                               qsizetype {aka long long int}
Copy link
Contributor

@uklotzde uklotzde left a comment

Choose a reason for hiding this comment

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

LGTM

The usage of qDebug() with the format string is uncommon, but let's leave it as is.

@uklotzde uklotzde merged commit f58138a into mixxxdj:main Oct 17, 2021
@Be-ing Be-ing deleted the qsizetype_to_int branch October 17, 2021 13:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants