Skip to content

Conversation

@hippietrail
Copy link
Collaborator

@hippietrail hippietrail commented Nov 29, 2025

Issues

Resolves #1509

Description

Flags "more/most " when the adjective has an inflected comparative/superlative form.

Note that this is not correcting an error and is not even always an improvement since native English speakers don't prefer some inflected adjective forms and they can seem clunky, awkward, or even wrong.

Because of this I've modified the lint_descriptions_are_clean test to turn off this one test. In the future it will likely make sense to replace this special case with an API etc. when there are other suggestions which won't mean that a description isn't clean.

I made lint_descriptions_are_clean in lint_group.rs easier to follow while I was at it by renaming variables and adding a nice comment.

While I was figuring that out, I rearranged the methods of LintGroup to group all the constructors together at the top before the other methods.

This linter's own message lets the user know it's not an error.

I also had to modify some dictionary entries that used the > annotation to make agent nouns from verbs ("time" → "timer" etc.) since they also assign the adjective property, resulting in false positives.

How Has This Been Tested?

Unit tests should cover all the variants and known false positives. Most are made up but false positives come from GitHub.

Checklist

  • I have performed a self-review of my own code
  • I have added tests to cover my changes

@hippietrail hippietrail marked this pull request as ready for review November 29, 2025 10:36
Copy link
Collaborator

@elijah-potter elijah-potter left a comment

Choose a reason for hiding this comment

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

I like these changes for the most part, but I think there's a better way to filter lints out of the lint description check.

let lints_to_check = LintGroup::new_curated(FstDictionary::curated(), Dialect::American);

let mut enforcer_config = LintGroupConfig::new_curated();
enforcer_config.set_rule_enabled("MoreAdjective", false);
Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't love the idea of disabling specific rules from this test. Our goal here is to make sure our descriptions are clean. If we want to ignore this rule becuase it's more of a stylistic choice, rather than a grammatical error, I think we should be ignoring specific LintKinds instead.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's totally fair of course. But one problem is that it often feels more like fixing an actual grammatical error, as in "more big" or "more long", whereas it seems like a stylistic choice for words like "funner" or "oftener".

It might be best solved by a new annotation flag or two for adjectives?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's totally fair of course. But one problem is that it often feels more like fixing an actual grammatical error, as in "more big" or "more long", whereas it seems like a stylistic choice for words like "funner" or "oftener".

It might be best solved by a new annotation flag or two for adjectives?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's totally fair of course. But one problem is that it often feels more like fixing an actual grammatical error, as in "more big" or "more long", whereas it seems like a stylistic choice for words like "funner" or "oftener".

It might be best solved by a new annotation flag or two for adjectives?

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.

Flag "more + adjective" when comparative exists

2 participants