restrict member access
parent
6400b1521b
commit
b564b3e57b
|
@ -1,7 +1,7 @@
|
|||
cmake_minimum_required(VERSION 3.5)
|
||||
include(cmake/color.cmake)
|
||||
|
||||
set(BLT_VERSION 0.14.12)
|
||||
set(BLT_VERSION 0.14.13)
|
||||
set(BLT_TEST_VERSION 0.0.1)
|
||||
|
||||
set(BLT_TARGET BLT)
|
||||
|
|
|
@ -567,12 +567,13 @@ namespace blt
|
|||
|
||||
class stats_t
|
||||
{
|
||||
friend bump_allocator;
|
||||
private:
|
||||
blt::size_t allocated_blocks = 0;
|
||||
blt::size_t allocated_bytes = 0;
|
||||
blt::size_t peak_blocks = 0;
|
||||
blt::size_t peak_bytes = 0;
|
||||
public:
|
||||
protected:
|
||||
inline void incrementBlocks()
|
||||
{
|
||||
allocated_blocks++;
|
||||
|
@ -596,27 +597,30 @@ namespace blt
|
|||
{
|
||||
allocated_bytes -= bytes;
|
||||
}
|
||||
|
||||
public:
|
||||
|
||||
inline auto getAllocatedBlocks()
|
||||
inline auto getAllocatedBlocks() const
|
||||
{
|
||||
return allocated_blocks;
|
||||
}
|
||||
|
||||
inline auto getAllocatedBytes()
|
||||
inline auto getAllocatedBytes() const
|
||||
{
|
||||
return allocated_bytes;
|
||||
}
|
||||
|
||||
inline auto getPeakBlocks()
|
||||
inline auto getPeakBlocks() const
|
||||
{
|
||||
return peak_blocks;
|
||||
}
|
||||
|
||||
inline auto getPeakBytes()
|
||||
inline auto getPeakBytes() const
|
||||
{
|
||||
return peak_bytes;
|
||||
}
|
||||
};
|
||||
|
||||
private:
|
||||
stats_t stats;
|
||||
|
||||
|
|
Loading…
Reference in New Issue