[all-commits] [llvm/llvm-project] 166301: [clang-tidy] Prevent `llvmlibc-inline-function-dec...

Joseph Huber via All-commits all-commits at lists.llvm.org
Sun Apr 16 08:58:59 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1663016b41d71a60f3d268607c6fbf16fcf85172
      https://github.com/llvm/llvm-project/commit/1663016b41d71a60f3d268607c6fbf16fcf85172
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2023-04-16 (Sun, 16 Apr 2023)

  Changed paths:
    M clang-tools-extra/clang-tidy/llvmlibc/InlineFunctionDeclCheck.cpp
    M clang-tools-extra/test/clang-tidy/checkers/llvmlibc/inline-function-decl.hpp

  Log Message:
  -----------
  [clang-tidy] Prevent `llvmlibc-inline-function-decl` triggering on lambdas

The `llvmlibc-inline-function-decl` check is intended to be used to
allow declarations in the `libc` project's header to be changed per-TU.
However, it is impossible to place this macro in front of a lambda so
this is not helpful. Additionally, lambdas are always going to have
internal linkage so they will not differ accross TUs.

Fixes https://github.com/llvm/llvm-project/issues/62147

Reviewed By: lntue, PiotrZSL

Differential Revision: https://reviews.llvm.org/D148444




More information about the All-commits mailing list