On Wed, Nov 27, 2002 at 01:59:45PM +0000, Angus Leeming wrote:
> This is inconsistent, would't compile on my box

That's funny, because it should.

> and will have Lars jumping up 
> and down crying "don't pass const int". For reasons I've yet to fathom.
> +++ lyxtext.h 27 Nov 2002 12:43:43 -0000
> +     void setCursorFromCoordinates(BufferView *,
> +             int x, int y, bool selecting = false) const;
>  +++ text2.C  27 Nov 2002 12:43:43 -0000
> void LyXText::setCursorFromCoordinates(BufferView * bview, LyXCursor & cur,
> -                                    int x, int y) const
> +                                    const int x, const int y, bool selecting) const

Oh, that's was a debugging aid I forgot to remove (for consistency
reasons). It just makes sure that x and y (the passed copy!) can't be
changed.

The function's signature is still 

 void LyXText::setCursorFromCoordinates(BufferView * bview, LyXCursor & cur,
   const int x, const int y, bool selecting) const

Toplevel 'const' is never "used".

Andre'




-- 
Those who desire to give up Freedom in order to gain Security,
will not have, nor do they deserve, either one. (T. Jefferson)

Reply via email to