Addison Wesley, 2008. - 464 p.
ISBN13: 978-0-13-607047-4
ISBN10: 0-13-607047-7
In defining a programming language idiom, an analogy with natural
language use might help. If I ask a friend, Do you know what time it is?
or equivalently Do you have a watch? , I would be surprised if she simply
said yes and turned away. These particular forms for asking someone for
the time of day are idiomatic in that they carry a meaning beyond their
literal interpretation. Similarly, a programming language idiom consists of
those patterns of use that good programmers accept as elegant, expressive
of their design intent, and that best harness the language’s power. Good
idiomaticstyletendstobespecifictoagivenlanguageorlanguage
paradigm: the way experienced programmers organize a Prolog program
would not constitute accepted Java style.