diff --git a/doc/src/manual/interfaces.md b/doc/src/manual/interfaces.md index 19c83f222a681..bf4d4ed09df07 100644 --- a/doc/src/manual/interfaces.md +++ b/doc/src/manual/interfaces.md @@ -618,3 +618,12 @@ broadcast!(f, dest, ::MyBroadcastStyle, As...) ``` Note the lack of bounds on `f`, `dest`, and `As...`. + +Third, simultaneously specializing on both the type of `dest` and the `BroadcastStyle` is fine. In this case, +it is also allowed to specialize on the types of the source arguments (`As...`). For example, these method signatures are OK: + +```julia +broadcast!(f, dest::DestType, ::MyBroadcastStyle, As...) +broadcast!(f, dest::DestType, ::MyBroadcastStyle, As::AbstractArray...) +broadcast!(f, dest::DestType, ::Broadcast.Scalar, As::Number...) +```