Skip to content

Commit bd39a6e

Browse files
author
Amanda Butler
authored
Copy edit FunctionPointerWithContext.h
Make minor copy edits, mostly for consistent tense across documentation.
1 parent 4bf95bc commit bd39a6e

File tree

1 file changed

+19
-19
lines changed

1 file changed

+19
-19
lines changed

features/FEATURE_BLE/ble/FunctionPointerWithContext.h

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -31,24 +31,24 @@
3131
/**
3232
* Function like object adapter over freestanding and member functions.
3333
*
34-
* Freestanding and member functions are two very distinct types in C++, one is
35-
* not convertible into the other and the call syntax between those two is very
36-
* different even if conceptually they are very similar: Both primitives can be
34+
* Freestanding and member functions are two distinct types in C++. One is
35+
* not convertible into the other, and the call syntax between the two is
36+
* different even if conceptually they are similar: Both primitives can be
3737
* copied, called and produce a result.
3838
*
39-
* To solve incompatibilities this class adapt freestanding and member function
39+
* To solve incompatibilities, this class adapts freestanding and member functions
4040
* to a common interface. The interface chosen is similar to the freestanding
4141
* function pointers interface:
42-
* - Copyable
43-
* - Nullable
44-
* - Callable
42+
* - Copyable.
43+
* - Nullable.
44+
* - Callable.
4545
*
4646
* This class also offers a mechanism to chain other instances to it. When an
4747
* instance is called, all the instances being part of the chain are called.
4848
*
4949
* @important freestanding or member function adapted must accept a single
50-
* argument and this argument shall be a pointer to ContextType. Adapted
51-
* primitives shall not return anything.
50+
* argument, and this argument is a pointer to ContextType. Adapted
51+
* primitives do not return anything.
5252
*
5353
* @tparam ContextType Type of the argument pointee.
5454
*/
@@ -72,10 +72,10 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
7272
}
7373

7474
/**
75-
* Create a FunctionPointerWithContext from a pointer to member function
76-
* and the instance which shall be used to call it.
75+
* Create a FunctionPointerWithContext from a pointer to a member function
76+
* and the instance which is used to call it.
7777
*
78-
* @param[in] object Pointer to the instance which will be used to invoke @p
78+
* @param[in] object Pointer to the instance which is used to invoke @p
7979
* member.
8080
* @param[in] Pointer to the member function to adapt.
8181
*/
@@ -113,7 +113,7 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
113113
/**
114114
* Adapt a freestanding function.
115115
*
116-
* Previous content adapted is discarded while it is replace by @p function.
116+
* Previous content adapted is discarded while @p function replaces it.
117117
*
118118
* @note This function is equivalent to a call to the copy assignment
119119
* operator.
@@ -129,13 +129,13 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
129129
/**
130130
* Adapt a pointer to member function and the instance to use to call it.
131131
*
132-
* Previous content adapted is discarded while it is replace by the
133-
* adaptation of the pair @p object and @p member.
132+
* Previous content adapted is discarded while the adaptation
133+
* of the pair @p object and @p member replaces it.
134134
*
135135
* @note This function is equivalent to a call to the copy assignment
136136
* operator.
137137
*
138-
* @param[in] object Pointer to the instance used to invoke @p member.
138+
* @param[in] object Pointer to the instance is used to invoke @p member.
139139
* @param[in] function Pointer to the member function to adapt.
140140
*/
141141
template<typename T>
@@ -185,7 +185,7 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
185185
/**
186186
* Indicate if a callable object is being adapted.
187187
*
188-
* @note implementation of safe bool operator
188+
* @note implementation of safe bool operator.
189189
*
190190
* @return true if the content of the instance can be invoked and false
191191
* otherwise.
@@ -199,7 +199,7 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
199199
* Set a FunctionPointer instance as the next element in the chain of
200200
* callable objects.
201201
*
202-
* @note Invoking call() on the head FunctionPointer will invoke all
202+
* @note Invoking call() on the head FunctionPointer invokes all
203203
* chained callbacks.
204204
*
205205
* @note Refer to CallChainOfFunctionPointerWithContext as an alternative.
@@ -279,7 +279,7 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
279279
/*
280280
* Forward declaration of a class and a member function to this class.
281281
* Because the compiler doesn't know anything about the forwarded member
282-
* function, it will always use the biggest size and the biggest alignment
282+
* function, it always uses the biggest size and the biggest alignment
283283
* that a member function can take for objects of type UndefinedMemberFunction.
284284
*/
285285
class UndefinedClass;

0 commit comments

Comments
 (0)