Skip to content

Commit

Permalink
fix docu
Browse files Browse the repository at this point in the history
  • Loading branch information
mschimek committed Sep 12, 2024
1 parent 906f237 commit c0bd627
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions include/kamping/data_buffer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ namespace kamping {

namespace internal {

/// @brief Base class containing logic to verify whether a buffer's data has already been extracted. This only has effects if an appropiate assertion level is set.
/// @brief Base class containing logic to verify whether a buffer's data has already been extracted. This only has
/// effects if an appropiate assertion level is set.
class Extractable {
protected:
/// @brief Set the extracted flag to indicate that the status stored in this buffer has been moved out.
Expand All @@ -72,13 +73,11 @@ class Extractable {
#endif
};

/// @brief Base object for parameter objects which deletes copy constructor (optionally) and assignment operator and
/// enables move.
/// @brief Class optionally containing a copy constructor while supporting move assignment/construction0
///
/// @tparam has_copy_constructor Indicates whether the copy constructor should be deleted.
/// @tparam enable_copy_constructor Indicates whether the copy constructor should be enabled.
/// You can inherit from this class privately.
/// While constructors are never inherited, the derived class still has no copy constructor (assignment), because it
/// can not be default constructed, due to the missing implementation in the base class. Because we provide a (default)
/// While constructors are never inherited, the derived class still has no copy constructor (if not especially enabled), because it can not be default constructed, due to the missing implementation in the base class. Because we provide a (default)
/// implementation for the move constructor (assignment) in the base class, the derived class can construct default
/// implementations.
template <bool /*enable_copy_constructor*/ = false>
Expand Down Expand Up @@ -171,8 +170,8 @@ static constexpr bool is_vector_bool_v<
template <typename T>
static constexpr bool
is_vector_bool_v<T, typename std::enable_if<has_value_type_v<std::remove_cv_t<std::remove_reference_t<T>>>>::type> =
is_specialization<std::remove_cv_t<std::remove_reference_t<T>>, std::vector>::value&&
std::is_same_v<typename std::remove_cv_t<std::remove_reference_t<T>>::value_type, bool>;
is_specialization<std::remove_cv_t<std::remove_reference_t<T>>, std::vector>::value
&& std::is_same_v<typename std::remove_cv_t<std::remove_reference_t<T>>::value_type, bool>;

KAMPING_MAKE_HAS_MEMBER(resize)

Expand Down Expand Up @@ -507,7 +506,8 @@ class DataBuffer : private CopyMoveEnabler<enable_copy_construction<ownership>>,
/// is not called if the buffer's resize policy is BufferResizePolicy::no_resize.
template <typename SizeFunc>
void resize_if_requested(SizeFunc&& compute_required_size) {
if constexpr (resize_policy == BufferResizePolicy::resize_to_fit || resize_policy == BufferResizePolicy::grow_only) {
if constexpr (resize_policy == BufferResizePolicy::resize_to_fit
|| resize_policy == BufferResizePolicy::grow_only) {
resize(compute_required_size());
}
}
Expand Down

0 comments on commit c0bd627

Please sign in to comment.