Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [handly-dev] bad comment for ISnapshot.isEqualTo

Hi!

Well, then the documentation for Snapshot.isEqualTo is misleading, as it says

     * <li><code>Snapshot</code>s which have expired are not equal 
     *  to all other snapshots

[I think "to _any_ other snapshots" would be a bit clearer]

regards,
Vlad


On Tue, Feb 24, 2015 at 8:13 AM, Vladimir Piskarev <pisv@xxxxx> wrote:
Hi Vlad,
 
Thanks for the notice, but... sorry, I cannot see a contradiction.
 
In fact, DocumentSnapshots can be equal even if they are expired,
in case both of them correspond to the same document and the same
modificationStamp (see #predictEquality).
 
The contract says what it says to allow flexibility in implementations.
Best regards,
Vladimir
 
The comment in ISnapshot says 

     * Returns whether the two snapshots are equal. If the snapshots are equal 
     * they have equal contents (or had had equal contents before one or both 
     * of them have expired). However, the converse is not necessarily true.

Which is wrong according to the implementation (and its comment): snapshots can be equal only if none of them is expired.

regards,
Vlad


_______________________________________________
handly-dev mailing list
handly-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/handly-dev


Back to the top