Skip to content

feat: depends based on→depends on#3660

Open
hippietrail wants to merge 1 commit into
Automattic:masterfrom
hippietrail:depends-based-on
Open

feat: depends based on→depends on#3660
hippietrail wants to merge 1 commit into
Automattic:masterfrom
hippietrail:depends-based-on

Conversation

@hippietrail

Copy link
Copy Markdown
Collaborator

Issues

N/A

Description

I heard somebody say "depends based on" in a YouTube video this morning, enunciated in a way that indicated there was no intervening punctuation. I did some Googling and Google's AI insisted this is a known/common mistake though it didn't give me any links discussing it. I was able to find a good few examples on GitHub.

But to me only some of them are clearly fixed by removing the "based". Others might be fixed by adding some kind of punctuation between "depends" and "based on". I asked two AIs and they seemed mostly to think removing "based" is always the fix. I don't trust them.

So I'm putting this PR here, marked for review, with the debugging code still present. Because it's not finished but I am soliciting review and draft PRs never get any feedback.

How Has This Been Tested?

cargo test

AI Disclosure

  • I am a human and didn't use any AI.
  • I used LLM features of my editor, but not an agent.
  • I used an AI agent interactively.
  • I am an agent or I got an agent to do the work autonomously.

I used some AI for the research but not for the code or examples.

If Your PR Implements or Enhances a Linter

  • I made up the sentences in the unit tests.
  • The sentences in the unit tests were generated by an AI.
  • I'm using examples from the bug report / feature request.
  • I collected real-world sentences for the unit tests.

Checklist

  • I have performed a self-review of my own code
  • I have added tests to cover my changes
  • I have considered splitting this into smaller pull requests.

@hippietrail hippietrail added help wanted Extra attention is needed rust Pull requests that update Rust code linting labels Jun 15, 2026
source: &[char],
context: Option<(&[Token], &[Token])>,
) -> Option<Lint> {
eprintln!("🚨 {}", format_lint_match(matched_tokens, context, source));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

We cannot allow global side effects in this function.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Sorry I left the debugging in because it's just here for review of what it does, not ready to go in yet. I noticed draft PRs never ever get looked at so I thought I'd try this. Sorry if the Description was too much of a wall of text to read my explanation.

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

Labels

help wanted Extra attention is needed linting rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants