pop() better

This commit is contained in:
Robin Müller 2020-05-05 19:07:11 +02:00
parent 88f229cef9
commit df9e66834e
1 changed files with 2 additions and 7 deletions

View File

@ -70,13 +70,8 @@ public:
}
ReturnValue_t pop() {
if(empty()) {
return EMPTY;
} else {
readIndex = next(readIndex);
--currentSize;
return HasReturnvaluesIF::RETURN_OK;
}
T value;
return this->retrieve(&value);
}
static const uint8_t INTERFACE_ID = CLASS_ID::FIFO_CLASS;