Skip to content

Conversation

@hugovk
Copy link
Member

@hugovkhugovk commented Mar 3, 2024

  • Remove the section "For C code that needs to support versions of Python older than 2.3...". I can add it back if needed.

  • Highlight the example C code with C syntax instead of Python.

  • Like PEP 8 (PEP 8: Add green and red sidbar for good and bad examples #3567), add green and red side borders "good" and "bad" examples. For this, I split this example into two blocks:

returnalbatross; /* correct */return(albatross); /* incorrect */
  • Format None as None, add a missing full stop. Remove some redundant PEP fields.

Example

Before After
imageimage

📚 Documentation preview 📚: https://pep-previews--3702.org.readthedocs.build/pep-0007/

Copy link
Contributor

@willingcwillingc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely @hugovk

@hugovkhugovk merged commit 3cdfdd9 into python:mainMar 29, 2024
@hugovkhugovk deleted the pep7-c-syntax-hightlighting branch March 29, 2024 13:05
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@hugovk@JelleZijlstra@willingc@Jamim