Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: type check alignment format specifiers #18799

Draft
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

jack-tutor
Copy link

@jack-tutor jack-tutor commented Mar 13, 2025

Introduces support for type checking the alignment format specifiers

I ran into this issue where an optional type was being formatted with < - but None types do not actually support these alignment spec strings.

I'm a little unsure how to approach this feature and what the overall philosophy for the format specs are - I don't know how one would write a complete list of the types that support a given spec type.

Inline (line 95) the code claims:

# Fill and align is valid for all builtin types.

@jack-tutor jack-tutor marked this pull request as draft March 13, 2025 15:31
Copy link
Contributor

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

Sign up for free to 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.

1 participant