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

🚨 Fix new warnings revealed by clang-tidy 18 #611

Merged
merged 4 commits into from
May 29, 2024

Conversation

burgholzer
Copy link
Member

Description

This PR aims to fix all the new warnings that were introduced in clang-tidy versions 18, which have been enabled with the switch to the [email protected].

The first commit, which should later be reverted, just triggers a full clang-tidy run on the whole codebase.

Checklist:

  • The pull request only contains commits that are related to it.
  • I have added appropriate tests and documentation.
  • I have made sure that all CI jobs on GitHub pass.
  • The pull request introduces no new warnings and follows the project's style guidelines.

@burgholzer burgholzer self-assigned this May 25, 2024
@burgholzer burgholzer added code quality Code quality improvements c++ Anything related to C++ code labels May 25, 2024
Copy link
Contributor

github-actions bot commented May 25, 2024

Cpp-Linter Report ⚠️

Some files did not pass the configured checks!

clang-tidy reports: 1 concern(s)
  • include/mqt-core/python/pybind11.hpp:5:10: error: [clang-diagnostic-error]

    'pybind11/pybind11.h' file not found

        5 | #include <pybind11/pybind11.h> // IWYU pragma: export
          |          ^~~~~~~~~~~~~~~~~~~~~

Have any feedback or feature suggestions? Share it here.

@burgholzer burgholzer force-pushed the fix-clang-tidy-17-18-warnings branch 2 times, most recently from 4917e91 to 2082b6f Compare May 29, 2024 09:49
@cda-tum cda-tum deleted a comment from codecov bot May 29, 2024
@burgholzer burgholzer force-pushed the fix-clang-tidy-17-18-warnings branch from 2082b6f to 139db51 Compare May 29, 2024 13:57
Copy link

codecov bot commented May 29, 2024

Codecov Report

Attention: Patch coverage is 96.66667% with 2 lines in your changes missing coverage. Please review.

Project coverage is 91.5%. Comparing base (9e0be09) to head (f63d3f8).
Report is 108 commits behind head on main.

Files with missing lines Patch % Lines
include/mqt-core/dd/statistics/Statistics.hpp 50.0% 1 Missing ⚠️
src/algorithms/GoogleRandomCircuitSampling.cpp 0.0% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##            main    #611     +/-   ##
=======================================
- Coverage   91.5%   91.5%   -0.1%     
=======================================
  Files        145     145             
  Lines      14591   14596      +5     
  Branches    2341    2343      +2     
=======================================
+ Hits       13364   13367      +3     
- Misses      1227    1229      +2     
Flag Coverage Δ
cpp 91.3% <96.6%> (-0.1%) ⬇️
python 99.7% <ø> (ø)
Files with missing lines Coverage Δ
include/mqt-core/Permutation.hpp 100.0% <100.0%> (ø)
include/mqt-core/QuantumComputation.hpp 92.3% <100.0%> (-0.2%) ⬇️
...qt-core/algorithms/GoogleRandomCircuitSampling.hpp 58.3% <ø> (ø)
...e/mqt-core/datastructures/DirectedAcyclicGraph.hpp 94.5% <ø> (ø)
include/mqt-core/datastructures/DirectedGraph.hpp 89.0% <100.0%> (+0.2%) ⬆️
include/mqt-core/datastructures/DisjointSet.hpp 100.0% <ø> (ø)
include/mqt-core/datastructures/Layer.hpp 89.1% <ø> (ø)
...nclude/mqt-core/datastructures/UndirectedGraph.hpp 90.7% <ø> (ø)
include/mqt-core/dd/Benchmark.hpp 87.5% <100.0%> (+1.7%) ⬆️
include/mqt-core/dd/CachedEdge.hpp 84.2% <ø> (ø)
... and 107 more

@burgholzer
Copy link
Member Author

The missing pybind11 include is inevitable in the current setup. Continuing to merge.

@burgholzer burgholzer merged commit 42005a9 into main May 29, 2024
32 of 34 checks passed
@burgholzer burgholzer deleted the fix-clang-tidy-17-18-warnings branch May 29, 2024 17:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Anything related to C++ code code quality Code quality improvements
Projects
Status: Done
Status: Done
Development

Successfully merging this pull request may close these issues.

1 participant