mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Add support for mat(all) as an alias to mat.reshaped(mat.size(),fix<1>);
This commit is contained in:
@@ -339,6 +339,8 @@ enum SideType {
|
||||
OnTheRight = 2
|
||||
};
|
||||
|
||||
|
||||
|
||||
/* the following used to be written as:
|
||||
*
|
||||
* struct NoChange_t {};
|
||||
|
||||
@@ -70,4 +70,13 @@ reshaped(NRowsType nRows, NColsType nCols, OrderType) const
|
||||
derived(), internal::get_runtime_value(nRows), internal::get_runtime_value(nCols));
|
||||
}
|
||||
|
||||
// Views as linear vectors
|
||||
|
||||
EIGEN_DEVICE_FUNC
|
||||
inline const Reshaped<const Derived,SizeAtCompileTime,1>
|
||||
operator()(const Eigen::internal::all_t&)
|
||||
{
|
||||
return Reshaped<const Derived,SizeAtCompileTime,1>(derived(),size(),1);
|
||||
}
|
||||
|
||||
#endif // EIGEN_PARSED_BY_DOXYGEN
|
||||
|
||||
Reference in New Issue
Block a user