[all-commits] [llvm/llvm-project] 5f571e: [NFC] [Frontend] Correct the use of 'auto' in Sema...

Chuanqi Xu via All-commits all-commits at lists.llvm.org
Tue Sep 6 19:45:48 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 5f571eeb3f764c6d97b81822464ea420adef2cf7
      https://github.com/llvm/llvm-project/commit/5f571eeb3f764c6d97b81822464ea420adef2cf7
  Author: Chuanqi Xu <yedeng.yd at linux.alibaba.com>
  Date:   2022-09-07 (Wed, 07 Sep 2022)

  Changed paths:
    M clang/lib/CodeGen/CGCoroutine.cpp
    M clang/lib/Sema/SemaCoroutine.cpp

  Log Message:
  -----------
  [NFC] [Frontend] Correct the use of 'auto' in SemaCoroutine and CGCoroutine

We should only use 'auto' in case we can know the type from the right
hand side of the expression. Also we need keep '*' around if the type is
a pointer actually. Few uses of 'auto' in SemaCoroutine.cpp and
CGCoroutine.cpp violates the rule. This commit tries to fix it.




More information about the All-commits mailing list