[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron added a comment. In D117435#3247137 , @rjmccall wrote: > I don't remember if this is written up anywhere, but clang has a longstanding > policy that style enforcement belongs in a linter rather than the compiler. > One programmer's "redundant" i

[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron added inline comments. Comment at: clang/test/Headers/x86-intrinsics-headers-clean.cpp:4-5 // RUN: %clang_cc1 -ffreestanding -triple x86_64-unknown-unknown -Wsystem-headers \ -// RUN: -Wcast-qual -fsyntax-only -flax-vector-conversions=none -x c++ -verify %s +// RUN:

[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread John McCall via Phabricator via cfe-commits
rjmccall requested changes to this revision. rjmccall added a comment. This revision now requires changes to proceed. I don't remember if this is written up anywhere, but clang has a longstanding policy that style enforcement belongs in a linter rather than the compiler. One programmer's "redun

[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron updated this revision to Diff 400399. Izaron added a comment. Herald added a reviewer: jdoerfert. Herald added a subscriber: sstefan1. Fix tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D117435/new/ https://reviews.llvm.org/D117435 File

[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron added a comment. I will provide more context in this comment. **Why this patch?** Clang currently has a warning for duplicating specifiers (`inline inline`, `extern extern`, `consteval consteval`, etc.), but has no warnings for redundant weaker specifiers. I suggest to add such a group o

[PATCH] D117435: [clang] Warning for inline constexpr functions

2022-01-16 Thread Evgeny Shulgin via Phabricator via cfe-commits
Izaron created this revision. Izaron added reviewers: rjmccall, rsmith. Izaron requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. "inline constexpr" and "inline consteval" function declarations are redundant and shall be written rather as "co