Stupid little iota of an idea

"Jérôme M. Berger" jeberger at free.fr
Wed Feb 9 13:54:20 PST 2011


Ary Manzana wrote:
> On 2/9/11 3:54 PM, bearophile wrote:
>> - There is no need to learn to use a function with a weird syntax like
>> iota, coming from APL. This makes Phobos and learning D a bit simpler.
> 
> I would recommend stop using "weird" names for functions. Sorry if this
> sounds a little harsh but the only reason I see this function is called
> "iota" is to demonstrate knowledge (or to sound cool). But programmers
> using a language don't care about whether the other programmer
> demonstrates knowledge behind a function name, they just want to get
> things done, fast.
> 
> I mean, if I want to create a range of numbers I would search "range".
> "iota" will never, ever come to my mind. D has to be more open to
> public, not only to people who programmed in APL, Go or are mathematics
> freaks. Guess how a range is called in Ruby? That's right, Range.
> 
> Another example: retro. The documentation says "iterates a bidirectional
> name backwards". Hm, where does "retro" appear in that text? If I want
> to iterate it backwards, or to reverse the order, the first thing I
> would write is reverse(range) or backwards(range), "retro" would never
> come to my mind.
> 
	Well, at least “retro” is compatible with the dictionary
signification of the word, so even though it is not the first word
that would come to mind when searching how to reverse a list, it
should be pretty self explanatory when reading existing code.

	OTOH, “iota” is not and could even be argued to be antonymous to
the dictionary meaning, which makes it all that much more difficult
to understand.

		Jerome
-- 
mailto:jeberger at free.fr
http://jeberger.free.fr
Jabber: jeberger at jabber.fr

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20110209/a984d0a5/attachment.pgp>


More information about the Digitalmars-d mailing list