Aaron Wisner

Results 63 comments of Aaron Wisner

Thanks for your testing. Were you using the dev branch, and did your testing make sure the interrupts masking worked properly? Concurrency bugs are really subtle, and it could appear...

So sorry, I just saw your response now! All that really needs to be tested is that the `ATOMIC() {}` macro is working properly. What I would do is something...

I don't think the normal master branch is safe on the ESP32, as the synchronization macros are [NOPed](https://github.com/wizard97/Embedded_RingBuf_CPP/blob/master/RingBufHelpers.h#L39). I do believe that the dev branch works properly with the ESP32,...

This is a good point. Some aggressive compilers might optimize and cause this behavior. There are a few solutions: 1. Declare the `_head` and `_numElements' as volatile. 2. Declare the...

I know this issue is old, but commenting anyways. Volatile is deprecated in modern C++ for almost every use case (including this one). The correct solution would be inserting a...

Yeah, you are right. If you break inside one of these blocks it will keep interrupts on. The dev version of the library uses a new way to mask and...

Everything looks good, thanks for the merge, a few questions though. 1. Why do you think there needs to be seperate alias methods for the same thing? (`push()`, `append()`, `add()`)...

> When the buffer allows modifying either end, add() is ambiguous as it doesn't make clear what it is doing exactly. Hence, append() and prepend() are better, since they are...

> Right. For the aliases, you could probably solve this using an anonymous union (to have multiple names for the same pointer), but you'd still have 4 methods of which...

Ok, I think you convinced me enough. I have just been thinking about the cleanest solution that gives you these advanced features without making the common case too complex. I'm...