fix(math): fix unary expression shape reporting

This commit is contained in:
2026-11-01 11:25:54 +01:00
parent a264009629
commit 377cd5941d
+1 -1
View File
@@ -51,7 +51,7 @@ struct unary_expression : expression_tag, ops_provider<unary_expression<E, Op>>
unary_expression(EFwd&& expr, OpFwd&& op = Op{}) // NOLINT unary_expression(EFwd&& expr, OpFwd&& op = Op{}) // NOLINT
: expr(std::forward<EFwd>(expr)), op(std::forward<OpFwd>(op)) {} : expr(std::forward<EFwd>(expr)), op(std::forward<OpFwd>(op)) {}
constexpr auto shape() const { return expr.shape(); } constexpr auto shape() const { return Op::shape(expr); }
auto coeff(std::size_t index) const { return op(index, std::as_const(expr)); } auto coeff(std::size_t index) const { return op(index, std::as_const(expr)); }
}; };