Improve circular buffer

This commit is contained in:
Baptiste Wicht 2016-08-17 20:30:40 +02:00
parent 109bf6f169
commit acb7cda4a1

View File

@ -51,6 +51,14 @@ public:
start = (start + 1) % Size; start = (start + 1) % Size;
return value; return value;
} }
void pop_last(){
if(end == 0){
end = Size - 1;
} else {
--end;
}
}
}; };
#endif #endif