*Etienne Grossmann writes:
 | comma, etc is in a word. +#define WORDCHAR(x) (!(
 | (x).par->IsSeparator((x).pos) \ + || (x).par->IsKomma((x).pos) \ +
 | || (x).par->IsHfill((x).pos) \ + || (x).par->IsFloat((x).pos) \ +
 | || (x).par->IsInset((x).pos)))

inline bool IsWordChar(LyXCursor const & x) {
        return !(x.par->IsSeparator(x.pos) 
                 || x.par->IsKomma(x.pos)
                 || x.par->IsHfill(x.pos)
                 || x.par->IsFloat(x.pos)
                 || x.par->IsInset(x.pos));
}

The main reason behind using inline functions instead of macros is
type safety. (and inline funcs can not play tricks on your arguments)

        Lgb

Reply via email to