Re: [exslt] Re: Function memoization
by Florent Georges other posts by this author
Jul 14 2006 5:26AM messages near this date
Re: [exslt] Re: Function memoization
|
[exslt] Re: exslt Digest, Vol 27, Issue 2 (Out of office)
& XSLT Frans Englich wrote:
> Perhaps it's better to simply map it into a call to
> fn:deep-equal()? Seems to simply spec'ing it.
IMHO, it is the wrong way, for two reasons:
- identity preserve more properties (at least the
identity itself), so the developer doesn't have to
bother because some property is not preserved (with
the counterpart that, in some cases, more memoized
values will be recorded, when identity is not
relevant);
- identity is tested fast (in the worst case scenario,
it is O(n) where n is the number of memoized values,
when no special search is performed, while deep-equal
is O(n*s), where s is the size of the values).
But as Colin pointed, it is not possible to test identity
on atomic items. But for them, IMHO, equality is the right
choice.
Regards,
--drkm
___________________________________________________________________________
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolut
ionnaire.
http://fr.mail.yahoo.com
_______________________________________________
exslt mailing list
list@[...].org
http://www.exslt.org/list
Thread:
Dimitre Novatchev
Colin Paul Adams
Dimitre Novatchev
Dimitre Novatchev
Colin Paul Adams
Florent Georges
James Fuller
Colin Paul Adams
Florent Georges
Dimitre Novatchev
Florent Georges
Dimitre Novatchev
Florent Georges
Dimitre Novatchev
Colin Paul Adams
Frans Englich
Florent Georges
|