Automattic / Automattic/harper

What means X → What does X mean (missing do-support in object-fronted questions)

Open
#3,458 0 comments 1 reaction 0 assignees View on GitHub
enhancement grammar harper-core linting
Dominant language
Rust
Stars
15.4k
Forks
627
Avg merge
1d 12h
Merged PRs (30d)
106

Description

**The Error**
Harper doesn't flag questions that omit [do-support](https://en.wikipedia.org/wiki/Do-support) when a wh-word (what, which, who, whom, whose, where, when, why, and how) is used in a question with a regular verb like mean. These questions need the helper verb do/does/did plus the subject before the main verb.

**Examples (2-3):**
1. "What means offline mode?" → "What does offline mode mean?"
2. "How works this feature?" → "How does this feature work?"
3. "Why fails the test?" → "Why does the test fail?"

**References**
* Wikipedia, [Do-support](https://en.wikipedia.org/wiki/Do-support) - explains when and why English questions need the helper verb *do*.

**Potential Edge Cases**
* **Wh-word as subject, not object:** "What means more to you, money or time?" is correct, here *what* is the subject of the sentence, so no do-support is needed. The rule should only fire when the wh-word is the fronted object.
* **"Means" as a noun:** "What means do we have to verify this?" or "By what means did they enter?" Here *means* is a noun, not a verb, so the sentence is correct.
* **Indirect questions:** "I wonder what means the most to him" - *what* is the subject of the inner clause, so no fix is needed.

Contributor guide

Open the contributing guide

Research direction

Start by locating Harper's grammar-rule implementation and existing tests for wh-questions or do-support. Check that the rule distinguishes a fronted object from a wh-word subject, noun uses of “means,” and indirect questions. Done means the three incorrect examples are corrected without changing the listed valid examples.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
64/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.