Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
gerryxiao
· 7y ago · 0 comments
Why boxed? just change to vec::<&dyn animal> and push reference of Dog to vec ,it should work. Isnot &dyn animal trait object?
Comments
[–]
albertgasset
7y ago
It works, but the point of the article remains the same because &dyn Animal is also a fat pointer.