Skip to content

Don't report 'tis, 'twould, etc. - #1918

Merged
windymilla merged 1 commit into
DistributedProofreaders:masterfrom
windymilla:init-apostrophe
Aug 2, 2026
Merged

Don't report 'tis, 'twould, etc.#1918
windymilla merged 1 commit into
DistributedProofreaders:masterfrom
windymilla:init-apostrophe

Conversation

@windymilla

Copy link
Copy Markdown
Collaborator

There is already a list of common initial apostrophe words, which is used in curly quote conversion, so it knows that is an apostrophe, not an opening straight quote.

I have repurposed that list to also say, don't report an apostrophe as an unexpected single quote if it's followed by one of those words.

Fixes #1917

This is the list of words (but with curly quotes instead of straight)

INIT_APOS_WORDS = (
    "'em",
    "'Tis",
    "'Tisn't",
    "'Tweren't",
    "'Twere",
    "'Twould",
    "'Twouldn't",
    "'Twas",
    "'Im",
    "'Twixt",
    "'Til",
    "'Scuse",
    "'Gainst",
    "'Twon't",
    "'Tain't",
)

It should work regardless of case.

There is already a list of common initial apostrophe words,
which is used in curly quote conversion, so it knows
that is an apostrophe, not an opening straight quote.

I have repurposed that list to also say, don't report an
apostrophe as an unexpected single quote if it's followed
by one of those words.

Fixes DistributedProofreaders#1917
@windymilla
windymilla requested a review from srjfoo August 1, 2026 20:23
@windymilla
windymilla merged commit ab4b523 into DistributedProofreaders:master Aug 2, 2026
1 check passed
@windymilla
windymilla deleted the init-apostrophe branch August 2, 2026 18:17
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.

Could curly quotes have a few more permitted apostrophe exceptions

2 participants