This is an archive of the discontinued LLVM Phabricator instance.

[clang-tidy] Adds QualifierAlignment to misc-const-correctness.
AbandonedPublic

Authored by Mordante on Aug 14 2022, 7:08 AM.

Details

Summary

The fixit for misc-const-correctness was hard-coded to use east const.
Clang-format has the option to change east const to west const, but
that's not fool-proof.

This adds a option to the checker to select the placement of the const.
The naming is based on clang-format For backwards compatibility the east
const is the default.

Also fixes the documentation; previously it suggested west const is the
default.

Diff Detail

Event Timeline

Mordante created this revision.Aug 14 2022, 7:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 14 2022, 7:08 AM
Mordante requested review of this revision.Aug 14 2022, 7:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 14 2022, 7:08 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript

Shouldn't east/west added as aliases?

Mordante abandoned this revision.Aug 14 2022, 8:54 AM

Duplicate of D131386

Thanks for the information. Can you integrate the additional fixes of this patch in yours; specifically the documentation and release notes fixes.