Skip to content

gdb libpython.py: Remove compatibility code#105739

Merged
vstinner merged 1 commit into
python:mainfrom
vstinner:gdb_remove_compat
Jun 14, 2023
Merged

gdb libpython.py: Remove compatibility code#105739
vstinner merged 1 commit into
python:mainfrom
vstinner:gdb_remove_compat

Conversation

@vstinner
Copy link
Copy Markdown
Member

@vstinner vstinner commented Jun 13, 2023

Remove compatibility code for Python 2 and early Python 3 versions.

  • Remove os_fsencode() reimplementation: use os.fsencode() directly. os.fsencode() was added to Python 3.2.
  • Remove references to Python 2 and "Python 3": just say "Python".
  • Remove outdated u'' string format: use '' instead.

@vstinner vstinner force-pushed the gdb_remove_compat branch from 92a1ae2 to 99c427b Compare June 13, 2023 19:07
@vstinner vstinner changed the title gdb libpython.py: Remove outdated code gdb libpython.py: Remove compatibility code Jun 13, 2023
@vstinner
Copy link
Copy Markdown
Member Author

cc @methane

Remove compatibility code for Python 2 and early Python 3 versions.

* Remove os_fsencode() reimplementation: use os.fsencode() directly.
  os.fsencode() was added to Python 3.2.
* Remove references to Python 2 and "Python 3": just say "Python".
* Remove outdated u'' string format: use '' instead.
@vstinner vstinner force-pushed the gdb_remove_compat branch from 99c427b to aa597a2 Compare June 13, 2023 19:16
@vstinner
Copy link
Copy Markdown
Member Author

Oh, I also removed u'' string format.

@vstinner vstinner merged commit 0316063 into python:main Jun 14, 2023
@vstinner vstinner deleted the gdb_remove_compat branch June 14, 2023 10:30
@vstinner
Copy link
Copy Markdown
Member Author

Merged, thanks for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants