Style question -- plural of class name?

Robert Kern robert.kern at gmail.com
Thu May 9 13:44:17 EDT 2013


On 2013-05-08 21:20, Roy Smith wrote:
> FooEntry is a class.  How would you describe a list of these in a
> docstring?
>
> "A list of FooEntries"
>
> "A list of FooEntrys"
>
> "A list of FooEntry's"
>
> "A list of FooEntry instances"
>
> The first one certainly sounds the best, but it seems wierd to change
> the spelling of the class name to make it plural.

I'm using services like Github more and more to talk about code, so I have taken 
to adopting its inline markup for `code` when referring to identifiers. Thus, I 
will often write

   A list of `FooEntry`s

But I don't mind

   A list of FooEntries

Hopefully there isn't also a `FooEntries` class.

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth."
   -- Umberto Eco




More information about the Python-list mailing list