Skip to content

♻️🎨 Code cleanup and refactors #798

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 11 commits into from
Jan 12, 2025
Merged

♻️🎨 Code cleanup and refactors #798

merged 11 commits into from
Jan 12, 2025

Conversation

burgholzer
Copy link
Member

Description

Starting the year with some obligatory code cleanup and refactors.
The individual commits and the commit messages should more or less convey the bigger changes.
For the most part, it's really all about defining clearer interfaces and following some new clang-tidy suggestions.

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 added usability Anything related to usability refactor Anything related to code refactoring code quality Code quality improvements minor Minor version update DD Anything related to the DD package Core Anything related to the Core library and IR c++ Anything related to C++ code labels Jan 10, 2025
@burgholzer burgholzer self-assigned this Jan 10, 2025
- opting for references where null values are not expected or accepted.
- moving code from headers to source files.
- fixing new clang-tidy warnings
- adding a little more noexcept were appropriate

Signed-off-by: burgholzer <[email protected]>
Replaced raw pointer usages with references across the codebase for improved clarity and type safety. This adjustment simplifies operations and ensures consistency, particularly when applying, measuring, or resetting operations in simulation and functionality logic. Corresponding tests have been updated to reflect this change.

Signed-off-by: burgholzer <[email protected]>
This is only used in one part of DDSIM that is scheduled for removal. And removed code is debugged code.

Signed-off-by: burgholzer <[email protected]>
these members had getters since a while back. there is no need to keep them as public members.

Signed-off-by: burgholzer <[email protected]>
@burgholzer burgholzer merged commit 5c3cb8e into main Jan 12, 2025
30 checks passed
@burgholzer burgholzer deleted the early-2025-cleanup branch January 12, 2025 18:55
burgholzer added a commit to munich-quantum-toolkit/qcec that referenced this pull request Jan 12, 2025
## Description

This PR updates the MQT Core version used in QCEC to the latest version.
This includes changes from munich-quantum-toolkit/core#798.
Algorithms are now constructed slightly differently and some of the
methods now take references instead of pointers.

This PR also fixes one compiler warning related to a potential
uniniatialized usage in the equivalence checking manager.

## Checklist:

<!---
This checklist serves as a reminder of a couple of things that ensure
your pull request will be merged swiftly.
-->

- [x] The pull request only contains commits that are related to it.
- [x] I have added appropriate tests and documentation.
- [x] I have made sure that all CI jobs on GitHub pass.
- [x] The pull request introduces no new warnings and follows the
project's style guidelines.
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 Core Anything related to the Core library and IR DD Anything related to the DD package minor Minor version update refactor Anything related to code refactoring usability Anything related to usability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant