@@ -1111,18 +1111,18 @@ impl<A, D> Array<A, D> where
1111
1111
}
1112
1112
}
1113
1113
1114
- impl <' a, A , D , E > $trt<Array <A , E >> for Array <A , D > where
1115
- A : Clone + $trt<A , Output =A >,
1116
- D : Dimension ,
1117
- E : Dimension ,
1114
+ /// Perform an elementwise arithmetic operation between **self** and **other**,
1115
+ /// and return the result.
1116
+ ///
1117
+ /// If their shapes disagree, **other** is broadcast to the shape of **self**.
1118
+ ///
1119
+ /// **Panics** if broadcasting isn't possible.
1120
+ impl <' a, A , D , E > $trt<Array <A , E >> for Array <A , D >
1121
+ where A : Clone + $trt<A , Output =A >,
1122
+ D : Dimension ,
1123
+ E : Dimension ,
1118
1124
{
1119
1125
type Output = Array <A , D >;
1120
- /// Perform an elementwise arithmetic operation between **self** and **other**,
1121
- /// and return the result.
1122
- ///
1123
- /// If their shapes disagree, **other** is broadcast to the shape of **self**.
1124
- ///
1125
- /// **Panics** if broadcasting isn't possible.
1126
1126
fn $mth ( mut self , other: Array <A , E >) -> Array <A , D >
1127
1127
{
1128
1128
// FIXME: Can we co-broadcast arrays here? And how?
@@ -1140,18 +1140,18 @@ impl<'a, A, D, E> $trt<Array<A, E>> for Array<A, D> where
1140
1140
}
1141
1141
}
1142
1142
1143
- impl <' a, A , D , E > $trt<& ' a Array <A , E >> for & ' a Array <A , D > where
1144
- A : Clone + $trt<A , Output =A >,
1145
- D : Dimension ,
1146
- E : Dimension ,
1143
+ /// Perform an elementwise arithmetic operation between **self** and **other**,
1144
+ /// and return the result.
1145
+ ///
1146
+ /// If their shapes disagree, **other** is broadcast to the shape of **self**.
1147
+ ///
1148
+ /// **Panics** if broadcasting isn't possible.
1149
+ impl <' a, A , D , E > $trt<& ' a Array <A , E >> for & ' a Array <A , D >
1150
+ where A : Clone + $trt<A , Output =A >,
1151
+ D : Dimension ,
1152
+ E : Dimension ,
1147
1153
{
1148
1154
type Output = Array <A , D >;
1149
- /// Perform an elementwise arithmetic operation between **self** and **other**,
1150
- /// and return the result.
1151
- ///
1152
- /// If their shapes disagree, **other** is broadcast to the shape of **self**.
1153
- ///
1154
- /// **Panics** if broadcasting isn't possible.
1155
1155
fn $mth ( self , other: & ' a Array <A , E >) -> Array <A , D >
1156
1156
{
1157
1157
// FIXME: Can we co-broadcast arrays here? And how?
0 commit comments