Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Michael Sandstedt <[email protected]>
  • Loading branch information
cecille and msandstedt authored Nov 4, 2021
1 parent 63dff11 commit 9edfb64
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/system/SystemObject.h
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ union ObjectArena
* This is the abstract base class for Static and Dynamic ObjectPool objects.
*
* @note
* This base class can be used to pass pointers to the sized ObjectPoolStatic and ObjectPoolDynamic classes withouth requiring
* the class holding the reference to be templated on the pool size.
* This base class can be used to pass pointers to the ObjectPoolDynamic and sized ObjectPoolStatic classes without requiring
* the class holding the reference to be templated on pool size.
*/
template <typename T>
class ObjectPoolBase
Expand Down Expand Up @@ -235,7 +235,7 @@ class ObjectPoolStatic : public ObjectPoolBase<T>
T * lReturn = nullptr;
(void) static_cast<Object *>(lReturn); /* In C++-11, this would be a static_assert that T inherits Object. */

unsigned int lIndex = 0;
size_t lIndex = 0;
for (lIndex = 0; lIndex < N; ++lIndex)
{
T & lObject = reinterpret_cast<T *>(mArena.uMemory)[lIndex];
Expand All @@ -247,7 +247,7 @@ class ObjectPoolStatic : public ObjectPoolBase<T>
}
}
#if CHIP_SYSTEM_CONFIG_PROVIDE_STATISTICS
unsigned int lNumInUse = 0;
size_t lNumInUse = 0;

if (lReturn != nullptr)
{
Expand Down Expand Up @@ -364,7 +364,7 @@ class ObjectPoolStatic : public ObjectPoolBase<T>
* @class ObjectPoolDynamic
*
* @brief
* This is the data class for dyanmic object pools.
* This is the data class for dynamic object pools.
*
* @tparam T a subclass of Object to be allocated.
*/
Expand Down

0 comments on commit 9edfb64

Please sign in to comment.