I could use additional insight.
On the one hand there is multidispatch and that had preferred
sin(x::TypeOfValue) .. end
sin(xs::Vector{TypeOfValue}) .. end
# and the uses
sin( value )
sin( values )
On the other one hand there is broadcasting and that prefers
sin(x::TypeOfValue) .. end
# and the uses
sin( value )
sin.( values )
Sometimes I do not know this:
Is my value
stands alone or is a vector of values or a fixed length array of values?
In that case I would have been inclined to define sin{T}( values::Vector{T} ) == sin.(values)
; but that is frowned upon (and, apparently, not costless even if it were accepted).
Is there a [relatively] new perspective that things that are a self-contained thing (as if length([thing…]) ==1) should not be used interchangeably with things that are a sequence of thing (as if length([thing…]) > 1)?