Steven D'Aprano <steve+comp.lang.pyt...@pearwood.info> writes: > Source code is, *by definition*, the definitive version. (It's the > SOURCE, see?) Zipping the source code just means that the *source* > inside the zip file is the definitive version, not the compressed > binary data.
I find the Free Software Foundation has a good, clear definition of “source” for programs: The "source code" for a work means the preferred form of the work for making modifications to it. (GNU General Public License, version 3 §1). There is ambiguity there, but it's exactly where it needs to be: focussing the discussion on what form of the work is preferred for making modofications to it. A byte stream is only source *with respect to some work*, and is only the source of *that* work if it is the preferred form of that work for making modifications to that work. This neatly cuts of at the knees a whole mob of futile speculative distractions about “who is to say whether one person might consider this byte stream to be source”. To hell with all that. We're interested in making modifications to a work, and we reach for some form of the work to do so: *that* form is the source for the work. > The AST is not definitive. Human beings write *text*, which is what > the source code is. And if it's not text in some outlying cases, then it will only be because some *other* form of the work which is preferred by actual human programmers for making modifications to the work. > Code is written primarily for human beings. Many programmers, and many > language designers, don't realise this, which is why so many programs > are write-only code. Presentation *is important*, and cannot always be > separated from semantics without hurting the primary audience, the > human reader. This is what code obfuscators do, deliberately: mangle > the presentation while keeping the semantics the same. You're > inadvertently proposing the same thing (albeit to a lesser degree). Yes. And this is why obfuscated code, though it may be interpreted without difficulty by the same compiler algorithm, still does not constitute the source for the program. -- \ “Any intelligent fool can make things bigger and more complex… | `\ It takes a touch of genius – and a lot of courage – to move in | _o__) the opposite direction.” —Albert Einstein | Ben Finney -- https://mail.python.org/mailman/listinfo/python-list