From: Richard J. <ri...@an...> - 2005-11-24 17:39:22
|
On Thu, Nov 24, 2005 at 05:29:46PM +0000, Amit Dubey wrote: > I can't see the CVS version, but I have a couple questions: > > (1) What is the point of having two rev functions? Arrays are indexed, you > can just access n-i instead of i. I'm not sure if the objection is to having 'Array.rev*' altogether or having two different versions of this function. Well, the point of having 'Array.rev' is simply because there is a 'List.rev'. 'Array.- rev_in_place' is an extension to the standard set of common functions which only applies to the special case of arrays because arrays are mutable. > (2) find_all should return a list. e.g. find_all in ExtHashtbl returns a > list. OK, but conversely List.find_all is defined as identical to List.filter. Hashtbl.find_all is quite a different function. It returns all values associated with a single key, and only makes sense because of a peculiarity of Hashtbl, namely that one can associate multiple values with a key. Rich. -- Richard Jones, CTO Merjis Ltd. Merjis - web marketing and technology - http://merjis.com Team Notepad - intranets and extranets for business - http://team-notepad.com |