A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2009-September/091925.html below:

[Python-Dev] Fuzziness in io module specs

[Python-Dev] Fuzziness in io module specs [Python-Dev] Fuzziness in io module specsGreg Ewing greg.ewing at canterbury.ac.nz
Sun Sep 20 03:11:53 CEST 2009
Steven D'Aprano wrote:

> Using "truncate" to mean "increase in size" makes about as much sense as 
> having a list method called "remove" used to insert items. I can't 
> imagine what the committee who approved this were thinking.

I expect the reason is historical. Some time back in the
early days of Unix, someone wanted a way of chopping back
files, so they added a truncate() system call. Then someone
else noticed that it would happily accept an argument greater
than the existing length, and it seemed like that could
be useful behaviour, so they documented it and left it that way.

Then the POSIX committee came along and incorporated it into
the standard so as to be compatible with existing practice.

-- 
Greg
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4