Conversation
f8c3e1a to
8afb85d
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a commit_wrapper class with a skeleton implementation and refactors the existing wrapper base class architecture. The main purpose is to provide a foundation for commit operations that can be quickly merged and improved incrementally.
- Extracts
wrapper_basetemplate class fromcommon.hppto its own dedicated header file - Updates all existing wrapper classes to use the new
wrapper_baselocation and addsnoexceptspecifiers - Introduces a new
commit_wrapperclass with basic functionality to retrieve the last commit
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
src/wrapper/wrapper_base.hpp |
New dedicated header containing the extracted wrapper_base template class with improved noexcept specifications |
src/wrapper/commit_wrapper.hpp |
New wrapper class declaration for Git commit operations |
src/wrapper/commit_wrapper.cpp |
Implementation of commit wrapper with destructor and last_commit static method |
src/wrapper/status_wrapper.hpp |
Updated include path and added noexcept to move operations |
src/wrapper/repository_wrapper.hpp |
Updated include path and added noexcept to move operations |
src/wrapper/refs_wrapper.hpp |
Updated include path and added noexcept to move operations |
src/wrapper/index_wrapper.hpp |
Updated include path and added noexcept to move operations |
src/wrapper/index_wrapper.cpp |
Added missing include for common.hpp |
src/utils/common.hpp |
Removed wrapper_base template class (moved to dedicated file) |
CMakeLists.txt |
Added new commit wrapper and wrapper base files to build configuration |
src/wrapper/commit_wrapper.hpp
Outdated
|
|
||
| ~commit_wrapper(); | ||
|
|
||
| commit_wrapper(commit_wrapper&&) = default; |
There was a problem hiding this comment.
The move constructor should be marked as noexcept to match the pattern used in other wrapper classes and the base class implementation.
Suggested change
| commit_wrapper(commit_wrapper&&) = default; | |
| commit_wrapper(commit_wrapper&&) noexcept = default; |
src/wrapper/commit_wrapper.hpp
Outdated
| ~commit_wrapper(); | ||
|
|
||
| commit_wrapper(commit_wrapper&&) = default; | ||
| commit_wrapper& operator=(commit_wrapper&&) = default; |
There was a problem hiding this comment.
The move assignment operator should be marked as noexcept to match the pattern used in other wrapper classes and the base class implementation.
Suggested change
| commit_wrapper& operator=(commit_wrapper&&) = default; | |
| commit_wrapper& operator=(commit_wrapper&&) noexcept = default; |
2890c13 to
1427367
Compare
SandrineP
approved these changes
Jul 17, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains a skeleton implementation of commit_wrapper only, so that it can be reviewed and merged quickly, and improved in future PRs without blocking anyone.