[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [cp-patches]: Patch: GapContent fix
From: |
Tom Tromey |
Subject: |
Re: [cp-patches]: Patch: GapContent fix |
Date: |
07 Sep 2005 11:57:56 -0600 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
>>>>> "Lillian" == Lillian Angel <address@hidden> writes:
Lillian> - if (mark <= gapStart)
Lillian> + if (mark <= gapStart || mark <= gapEnd)
Isn't gapEnd >= gapStart?
So the first test is redundant?
Also, in passing, I wonder whether GapContent should use an ArrayList
rather than a LinkedList to store the list of positions, for
efficiency. In particular a binarySearch (performed in several places
on 'positions') is more efficient on an ArrayList.
Tom