From: Jean-Marc Lasgouttes Date: Mon, 20 Nov 2006 14:07:30 +0000 (+0000) Subject: * MathMacroArgument.C (MathMacroArgument): do not use convert<> since X-Git-Tag: 1.6.10~11810 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=502f07307f77254affd074d2a15a2faae518b206;hp=f966f2d1b7f1c0baa212ba798160288b4208d989;p=lyx.git * MathMacroArgument.C (MathMacroArgument): do not use convert<> since it may be too slow. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15996 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/mathed/MathMacroArgument.C b/src/mathed/MathMacroArgument.C index 3bb72bde94..999079b640 100644 --- a/src/mathed/MathMacroArgument.C +++ b/src/mathed/MathMacroArgument.C @@ -15,7 +15,6 @@ #include "InsetMathMacro.h" #include "MathStream.h" #include "MathSupport.h" -#include "support/convert.h" #include "debug.h" @@ -34,7 +33,13 @@ MathMacroArgument::MathMacroArgument(size_t n) lyxerr << "MathMacroArgument::MathMacroArgument: wrong Argument id: " << n << endl; } - str_ = '#' + convert(n); + // The profiler tells us not to use + // str_ = '#' + convert(n); + // so we do the conversion of n to ASCII manually. + // This works because 1 <= n <= 9. + str_.resize(2); + str_[0] = '#'; + str_[1] = '0' + n; }