Eric Snow added the comment:

Here's an outline of how I see __main__.__spec__ playing out relative to the 
various cmdline interfaces.

== == == === ==== ======== ======== ======== ======== ============
-  -c -m dir file name     loader   origin   cached   has_location
== == == === ==== ======== ======== ======== ======== ============
                  __main__ builtin  -        None     False
X                 __main__ builtin  -        None     False
   X              __main__ builtin  -c       None     False
      X           (finder) (finder) (finder) (finder) (finder)
         X        __main__ <loader> path     None     True
             X    __main__ <loader> path     None     True
== == == === ==== ======== ======== ======== ======== ============

Note: __main__.__spec__ in the -m case is addressed in issue #19700.

Thoughts?

See:

[1] http://docs.python.org/3.4/using/cmdline.html
[2] Python/pythonrun.c
[3] Modules/main.c

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue19697>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to