>>>>> "Andre" == Andre Poenitz <[EMAIL PROTECTED]> writes:
Andre> On Fri, Sep 05, 2003 at 06:01:12PM +0200, Asger Kunuk Alstrup Andre> wrote: >> On Fri, 5 Sep 2003, Angus Leeming wrote: >> >> > support/textutils.h cannot currently be compiled stand-alone. To >> do so would > require a > #include "paragraph.h". >> > >> > inline > bool IsInsetChar(char c) > { > return (c == >> Paragraph::META_INSET); >> > } >> > >> > So, should I do that or should I move this function out-of-line? >> >> I would not be surprised if this turns up in profiles, if you >> outline it. Andre> What about 'manual inlining', i.e. instead of Andre> if (IsInsetChar(c)) Andre> write Andre> if (c == Paragraph::META_INSET) Andre> whenever it is needed? Absolutely agreed. I think that IsInsetChar should just die, since it is really Paragraph-related. The only place where this is a problem is in /// return true if the char forms part of a word inline bool IsWordChar(unsigned char c) { return !(IsSeparatorChar(c) || IsKommaChar(c) || IsInsetChar(c)); } However, this is completely wrong, since some insets are actually part of a word (when Inset::isLetter returns true). Fortunately, isWordChar is only used by Paragraph::isWord, which itself could very well use Inset::isLetter when relevant. JMarc