File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -68,8 +68,9 @@ macro_rules! impl_least_squares {
68
68
let mut a_t = None ;
69
69
let a_layout = match a_layout {
70
70
MatrixLayout :: C { .. } => {
71
- a_t = Some ( unsafe { vec_uninit( a. len( ) ) } ) ;
72
- transpose( a_layout, a, a_t. as_mut( ) . unwrap( ) )
71
+ let ( layout, t) = transpose( a_layout, a) ;
72
+ a_t = Some ( t) ;
73
+ layout
73
74
}
74
75
MatrixLayout :: F { .. } => a_layout,
75
76
} ;
@@ -78,8 +79,9 @@ macro_rules! impl_least_squares {
78
79
let mut b_t = None ;
79
80
let b_layout = match b_layout {
80
81
MatrixLayout :: C { .. } => {
81
- b_t = Some ( unsafe { vec_uninit( b. len( ) ) } ) ;
82
- transpose( b_layout, b, b_t. as_mut( ) . unwrap( ) )
82
+ let ( layout, t) = transpose( b_layout, b) ;
83
+ b_t = Some ( t) ;
84
+ layout
83
85
}
84
86
MatrixLayout :: F { .. } => b_layout,
85
87
} ;
You can’t perform that action at this time.
0 commit comments