A RetroSearch Logo

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

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2012-October/122117.html below:

[Python-Dev] Split unicodeobject.c into subfiles?

[Python-Dev] Split unicodeobject.c into subfiles?Chris Angelico rosuav at gmail.com
Sun Oct 7 23:33:57 CEST 2012
On Mon, Oct 8, 2012 at 8:17 AM, Victor Stinner <victor.stinner at gmail.com> wrote:
> Another problem with huge files is to handle "dependencies" with
> static functions. If the function A calls the function B which calls
> the function C, you have to order A, B and C "correctly" if these
> functions are private and not declared at the top of the file.
>
> If functions are grouped correctly, you just lhave to add the function
> to the right file, or reorder the files.

This isn't a fundamental problem, since you can always declare a
private function if it's mutually recursive with another private
function. But - forgive me if this is false in CPython - this isn't
usually that common. Also, ordering the functions in (at least an
approximation of) Define Before Use makes it easy to locate the one
you're calling, even in a non-smart editor: just go to the top of the
file and search for the function's name; the first hit will be the
definition. It's not usually difficult to sort functions
appropriately, and can pay dividends in readability.

ChrisA
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