mirror of
https://github.com/boostorg/histogram.git
synced 2025-05-11 05:07:58 +00:00
bug-fix
This commit is contained in:
parent
60b21171a6
commit
0226af858e
@ -33,11 +33,10 @@ public:
|
|||||||
|
|
||||||
inline void increase(size_type i) {
|
inline void increase(size_type i) {
|
||||||
switch (depth_) {
|
switch (depth_) {
|
||||||
case 0: depth_ = 1; create();
|
|
||||||
case sizeof(wtype): {
|
case sizeof(wtype): {
|
||||||
wtype& b = ((wtype*)buffer_)[i];
|
wtype& b = ((wtype*)buffer_)[i];
|
||||||
b += 1.0;
|
b += 1.0;
|
||||||
}
|
} break;
|
||||||
#define BOOST_HISTOGRAM_NSTORE_INC(T) \
|
#define BOOST_HISTOGRAM_NSTORE_INC(T) \
|
||||||
case sizeof(T): { \
|
case sizeof(T): { \
|
||||||
T& b = ((T*)buffer_)[i]; \
|
T& b = ((T*)buffer_)[i]; \
|
||||||
@ -45,6 +44,7 @@ public:
|
|||||||
grow(); /* and fall to next case */ \
|
grow(); /* and fall to next case */ \
|
||||||
else { ++b; break; } \
|
else { ++b; break; } \
|
||||||
}
|
}
|
||||||
|
case 0: depth_ = sizeof(uint8_t); create();
|
||||||
BOOST_HISTOGRAM_NSTORE_INC(uint8_t);
|
BOOST_HISTOGRAM_NSTORE_INC(uint8_t);
|
||||||
BOOST_HISTOGRAM_NSTORE_INC(uint16_t);
|
BOOST_HISTOGRAM_NSTORE_INC(uint16_t);
|
||||||
BOOST_HISTOGRAM_NSTORE_INC(uint32_t);
|
BOOST_HISTOGRAM_NSTORE_INC(uint32_t);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user