Open wnederpel opened 2 months ago
Hi @wnederpel yeah this is not something that Bumper can support, but it should fail in a more graceful way, I'll try to fix this soon.
@MasonProtter instead, could @alloc
just fall back to a normal array allocation?
If I am writing a function for generic input type Vector{T}
, right now, I have to write two separate methods:
But the code itself is basically the same. This leads to dangerous “shotgun edits” where I have to update the code in both places whenever I add a feature.
Can Bumper.jl itself just do a regular allocation if the type is not concrete?
You could then have an @alloc(…, strict=true)
to disable fallbacks.
Yeah that sounds pretty reasonable to do.
First of all: cool package and thanks for your work!
While I was working with the package I encountered an error starting with "Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks." so here is that bug report.
I wanted to allocate some memory for an array with an abstract eltype. Here is a minimal (not) working example:
I suppose the answer might be 'you cannot define sizeof for your abstract type and expect things to work', but I wanted to open this bug report anyway as requested.
Here is the full stack trace: