[issue40080] Stripping annotations out as a new optimization mode

2021-09-13 Thread Filipe Laíns
Change by Filipe Laíns : -- nosy: +FFY00 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40080] Stripping annotations out as a new optimization mode

2020-11-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: Corrected link: https://bugs.python.org/issue36466 -- superseder: -> Adding a way to strip annotations from compiled bytecode ___ Python tracker

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Raymond Hettinger
Raymond Hettinger added the comment: Duplicate of https://bugs.python.org/issue3646 This was rejected because it breaks functools.singledispatch(), typing.NamedTuple(), and dataclasses.dataclass(). Also the space savings was negligible -- typically take much less space than for docstrings

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I am -1 to this feature because compared with other optimization levels this can have unknown effects on the runtime, especially on dependencies you do not control. dataclasses is an example, but much more exist. To support this feature we would need

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Batuhan Taskaya
Batuhan Taskaya added the comment: > Note that dataclasses will break without annotations. Yes, that is also affecting this simple tester script. There is no alternative to value-less annotated assignment. I don't think this is preferable but just for information, these are the results for

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Eric V. Smith
Eric V. Smith added the comment: Note that dataclasses will break without annotations. -- nosy: +eric.smith ___ Python tracker ___

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Batuhan Taskaya
New submission from Batuhan Taskaya : Just like docstrings, annotations do nothing at runtime for the majority of the time. We can just strip out them and gain as much as the docstring optimization in bytecode size on a fully annotated repo. For comparing these two optimizations, I

[issue40080] Stripping annotations out as a new optimization mode

2020-03-26 Thread Batuhan Taskaya
Batuhan Taskaya added the comment: As an addition, I need to clarify that each optimization applied by its own. -- ___ Python tracker ___