Brett Cannon added the comment:
It's something that could potentially be changed in the future, but no one has
prioritized it enough to worry about it. Typically this opens a pandora's box
of wanting to generalize it so it supports custom user optimizations as well
and then people lose
New submission from Matthew Fernandez:
Perhaps others wouldn't consider this a bug, but it was definitely surprising
to me. When switching between optimisation levels -OO (optimise and strip
docstrings) and -O (just optimise), you will find the docstrings are still
stripped. E.g.
$ ls
Antoine Pitrou added the comment:
Not really intentional, it's just a limitation of the current implementation
(where the same .pyo files are used for both -O and -OO). Already reported as
issue1538778 (which was closed as won't fix).
--
nosy: +barry, pitrou
superseder: - pyo's are
Matthew Fernandez added the comment:
Ah thanks, Antoine. Sorry, failed to find that issue in my prior searching.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue21489
___