In a simple case, such as
v = collect(1:10) sqrs = similar(v) map!(abs2, sqrs, v)
would it be better to use
broadcast!? I am using the
! form (instead of a
.= assignment) because this expression could be part of a larger expression. My guess is that
broadcast! could be preferred if there was a chance that it could be fused with other operations.