broadcasting treats things as vectors by default. If you want broadcasting to treat MyType as a scalar, define Base.broadcastable(x::MyType) = Ref(x)
1 Like
broadcasting treats things as vectors by default. If you want broadcasting to treat MyType as a scalar, define Base.broadcastable(x::MyType) = Ref(x)