[Tutor] doctest question

Steven D'Aprano steve at pearwood.info
Mon Nov 26 23:34:04 CET 2012


On 27/11/12 09:02, Steven D'Aprano wrote:

> Here's my attempt:

> def _setMultRespDefsEx(multRespDefs):
> """Format a dictionary of stuff as a string. Expects that dict contains:
[...]
> KNOWN BUGS:
>
> 1) Sometimes this function returns a dict instead of a string.
> 2) The formatted string output is ambiguous.
>
> """

Oops, I forgot one:

   3) This modifies the input argument. Never call this function except on
      a temporary deep copy of your dict.



-- 
Steven


More information about the Tutor mailing list