[all-commits] [llvm/llvm-project] 9be3c0: Undef the `DEFINE_C_API_STRUCT` macro after using ...

Mehdi Amini via All-commits all-commits at lists.llvm.org
Mon Nov 2 11:19:03 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 9be3c01eb989a1729ea34ebe102b3716acfe5223
      https://github.com/llvm/llvm-project/commit/9be3c01eb989a1729ea34ebe102b3716acfe5223
  Author: Mehdi Amini <joker.eph at gmail.com>
  Date:   2020-11-02 (Mon, 02 Nov 2020)

  Changed paths:
    M mlir/include/mlir-c/AffineExpr.h
    M mlir/include/mlir-c/AffineMap.h
    M mlir/include/mlir-c/IR.h

  Log Message:
  -----------
  Undef the `DEFINE_C_API_STRUCT` macro after using it in the MLIR C API header (NFC)

Leaking macros isn't a good practice when defining headers. This
requires to duplicate the macro definition in every header though, but
that seems like a better tradeoff right now.

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




More information about the All-commits mailing list