Closed llogiq closed 4 years ago
Perhaps on-stack dynamic dispatch?
That sounds good to me ☺️
It's been a while since there was any movement on this. Is there something I should do or is this good to merge?
@lambda-fairy @Manishearth anyone?
Hey @llogiq!
Sorry, I've had way too many things going on lately 😢
It looks like the document is still called ootb-dyn-dispatch.md
. Can you please rename that to something like on-stack-dyn-dispatch.md
?
Otherwise it looks good to me 👍
I suppose LLVM always eliminates the duplicate stack usage here, so there is never a reason to do this with a union.
@llogiq I think you could also add an example for Option
. I saw it somewhere in some blog posts.
@pickfire I've noted in the "see also" section that Option.as_ref()
solves most of the same problem for us.
Moved the file and rebased. @lambda-fairy r?
Great write up! I was a bit confused by the title at first, perhaps something along the lines of “Dynamic Dispatch without Box”?