Skip to content

Conversation

@jll63
Copy link
Collaborator

@jll63 jll63 commented Dec 14, 2025

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR aims to remove extra semicolons from the codebase. However, while some changes are valid (removing unnecessary semicolons after function definitions), the PR incorrectly removes required semicolons from macro definitions, which will break compilation.

  • Correctly removes unnecessary semicolons after function body closing braces in non-macro contexts
  • Reformats trailing return type declarations for better readability
  • Incorrectly removes required semicolons from three macro definitions

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
include/boost/openmethod/policies/vptr_vector.hpp Correctly removes unnecessary semicolon after finalize() function body
include/boost/openmethod/macros.hpp Incorrectly removes required semicolons from macro definitions at lines 82, 91, and 141; also reformats trailing return types
include/boost/openmethod/detail/static_list.hpp Correctly removes unnecessary semicolons after friend operator function bodies in iterator classes

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

}
} \
template<typename...> \
struct BOOST_OPENMETHOD_OVERRIDERS(NAME)
Copy link

Copilot AI Dec 14, 2025

Choose a reason for hiding this comment

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

The semicolon at the end of this struct declaration should not be removed. This is part of a macro definition (BOOST_OPENMETHOD), and the struct declaration needs to end with a semicolon for proper syntax. Users of this macro will not add a semicolon after the macro invocation since the macro previously provided it.

Suggested change
struct BOOST_OPENMETHOD_OVERRIDERS(NAME)
struct BOOST_OPENMETHOD_OVERRIDERS(NAME);

Copilot uses AI. Check for mistakes.
using type = \
decltype(BOOST_OPENMETHOD_GUIDE(NAME)(std::declval<A>()...)); \
};
}
Copy link

Copilot AI Dec 14, 2025

Choose a reason for hiding this comment

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

The semicolon at the end of this struct definition should not be removed. This is part of a macro definition (BOOST_OPENMETHOD_DETAIL_LOCATE_METHOD), and the struct definition needs to end with a semicolon for proper syntax. Users of this macro will expect the semicolon to be included in the expansion.

Suggested change
}
};

Copilot uses AI. Check for mistakes.

#define BOOST_OPENMETHOD_CLASSES(...) \
BOOST_OPENMETHOD_REGISTER(::boost::openmethod::use_classes<__VA_ARGS__>);
BOOST_OPENMETHOD_REGISTER(::boost::openmethod::use_classes<__VA_ARGS__>)
Copy link

Copilot AI Dec 14, 2025

Choose a reason for hiding this comment

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

The semicolon at the end of this statement should not be removed. This is part of a macro definition (BOOST_OPENMETHOD_CLASSES), and the statement needs to end with a semicolon for proper syntax. Users of this macro will not add a semicolon after the macro invocation since the macro previously provided it.

Suggested change
BOOST_OPENMETHOD_REGISTER(::boost::openmethod::use_classes<__VA_ARGS__>)
BOOST_OPENMETHOD_REGISTER(::boost::openmethod::use_classes<__VA_ARGS__>);

Copilot uses AI. Check for mistakes.
@cppalliance-bot
Copy link

An automated preview of the documentation is available at https://52.openmethod.prtest3.cppalliance.org/libs/openmethod/doc/html/index.html

If more commits are pushed to the pull request, the docs will rebuild at the same URL.

2025-12-14 20:50:12 UTC

@codecov
Copy link

codecov bot commented Dec 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.02%. Comparing base (e0ead3b) to head (50a5fac).
⚠️ Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop      #52      +/-   ##
===========================================
- Coverage    92.03%   92.02%   -0.01%     
===========================================
  Files           40       40              
  Lines         2838     2835       -3     
  Branches      1354     1354              
===========================================
- Hits          2612     2609       -3     
  Misses         187      187              
  Partials        39       39              
Files with missing lines Coverage Δ
include/boost/openmethod/detail/static_list.hpp 96.96% <ø> (-0.14%) ⬇️
include/boost/openmethod/policies/vptr_vector.hpp 100.00% <ø> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ef48e48...50a5fac. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

Extra ';' inside a struct (-Wextra-semi warning in Clang) in the BOOST_OPENMETHOD_OVERRIDE macro

2 participants