mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[poincare/absolute_value] AbsoluteValue has no Unit
shallowReduce returns Undefined if its unique child has a Unit
This commit is contained in:
committed by
Émilie Feral
parent
032723eae1
commit
121e16a6a5
@@ -33,7 +33,6 @@ public:
|
||||
Evaluation<double> approximate(DoublePrecision p, Context * context, Preferences::ComplexFormat complexFormat, Preferences::AngleUnit angleUnit) const override {
|
||||
return ApproximationHelper::Map<double>(this, context, complexFormat, angleUnit, computeOnComplex<double>);
|
||||
}
|
||||
Expression getUnit() const override;
|
||||
|
||||
// Layout
|
||||
Layout createLayout(Preferences::PrintFloatMode floatDisplayMode, int numberOfSignificantDigits) const override;
|
||||
|
||||
@@ -19,10 +19,6 @@ Expression AbsoluteValueNode::setSign(Sign s, ReductionContext reductionContext)
|
||||
return AbsoluteValue(this);
|
||||
}
|
||||
|
||||
Expression AbsoluteValueNode::getUnit() const {
|
||||
return childAtIndex(0)->getUnit();
|
||||
}
|
||||
|
||||
Layout AbsoluteValueNode::createLayout(Preferences::PrintFloatMode floatDisplayMode, int numberOfSignificantDigits) const {
|
||||
return AbsoluteValueLayout::Builder(childAtIndex(0)->createLayout(floatDisplayMode, numberOfSignificantDigits));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user