This is an archive of the discontinued LLVM Phabricator instance.

[clangd] Enable configuring include insertions
Needs ReviewPublic

Authored by njames93 on Nov 10 2022, 10:57 AM.

Diff Detail

Event Timeline

njames93 created this revision.Nov 10 2022, 10:57 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 10 2022, 10:57 AM
Herald added a subscriber: arphaman. · View Herald Transcript
njames93 requested review of this revision.Nov 10 2022, 10:57 AM

The replacement rules design is just too complicated I'm afraid.
It's unclear that it solves a widespread problem, and even when there is one and the solution applies, the result is still difficult to use.

Angles vs quotes is something we've had multiple reports on, though, and may be narrow enough to find a simple solution.

  • maybe something config-based like Style: { IncludeAngled: 'match/a/suffix/.*' }
  • or something based on seeing how the header is included and storing this in the index. This is nice as it avoids config, but seems complicated in other ways (unpredictable, relies on complete index, can go wrong, may regress existing behavior)