-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[bug] Type assert of filter fails for empty CircularBuffer
#810
Comments
kunzaatko
changed the title
[bug] Type assert of filter fails for emtpy
[bug] Type assert of filter fails for empty May 8, 2022
CircularBuffer
CircularBuffer
This can be fixed by defining:
Are there any downsides to this? If now I can prepare a PR. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Replicate
Specifying the eltype does not fix the issue
Desired behaviour
It should behave the same way as with a
Vector
type.Possible solution
Since filter, returns a
Vector
type forCircularBuffer
there are two solutions that both produce an ideologically different ouput:filter
method forCircularBuffer
to use the method withArray
on the underlining buffer and notAbstractArray
on the struct,filter
method and make it return a newCircularBuffer
.I would think that the second option is the way to go since it would be easy for the user to use the method outputing
Vector
on demand.Can you assign me?
The text was updated successfully, but these errors were encountered: