From e12fa18c69cbe1f441e972f3519d33638f15658e Mon Sep 17 00:00:00 2001 From: Gabor Kelemen Date: Sun, 19 Apr 2020 20:36:58 +0200 Subject: tdf#42949 Simplify use of rtl::math::approxEqual in include/basegfx/ Turns out we can save about 500Mb of preprocessor input if we use rtl_math_approxEqual from rtl/math.h instead of its C++ wrapper rtl::math::approxEqual from rtl/math.hxx and manage the fallout accordingly. Before: bin/includebloat.awk | head sum total bytes included (excluding system headers): 19017296671 After: $ bin/includebloat.awk | head sum total bytes included (excluding system headers): 18535432672 Change-Id: I1691171f3a309405a7099882ad9989d147f59118 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92508 Tested-by: Jenkins Reviewed-by: Miklos Vajna --- include/basegfx/numeric/ftools.hxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'include/basegfx/numeric') diff --git a/include/basegfx/numeric/ftools.hxx b/include/basegfx/numeric/ftools.hxx index a272cb76b22c..78f4eb1e722f 100644 --- a/include/basegfx/numeric/ftools.hxx +++ b/include/basegfx/numeric/ftools.hxx @@ -19,7 +19,9 @@ #pragma once -#include +#include +#include +#include #include #include #include @@ -194,7 +196,7 @@ namespace basegfx static bool equal(const double& rfValA, const double& rfValB) { // changed to approxEqual usage for better numerical correctness - return rtl::math::approxEqual(rfValA, rfValB); + return rtl_math_approxEqual(rfValA, rfValB); } static bool equal(const double& rfValA, const double& rfValB, const double& rfSmallValue) -- cgit