[all-commits] [llvm/llvm-project] dcd747: [clang] p0388 conversion to incomplete array

Nathan Sidwell via All-commits all-commits at lists.llvm.org
Tue Oct 12 07:35:53 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: dcd74716f9d18444a17de852a760cc85bd16f825
      https://github.com/llvm/llvm-project/commit/dcd74716f9d18444a17de852a760cc85bd16f825
  Author: Nathan Sidwell <nathan at acm.org>
  Date:   2021-10-12 (Tue, 12 Oct 2021)

  Changed paths:
    M clang/include/clang/AST/ASTContext.h
    M clang/lib/AST/ASTContext.cpp
    M clang/lib/CodeGen/CGExpr.cpp
    M clang/lib/CodeGen/CGExprScalar.cpp
    M clang/lib/CodeGen/CGObjC.cpp
    M clang/lib/Sema/SemaCast.cpp
    M clang/lib/Sema/SemaExprCXX.cpp
    M clang/lib/Sema/SemaOverload.cpp
    M clang/test/CXX/drs/dr3xx.cpp
    A clang/test/CodeGenCXX/cxx20-p0388-unbound-ary.cpp
    A clang/test/SemaCXX/cxx20-p0388-unbound-ary.cpp

  Log Message:
  -----------
  [clang] p0388 conversion to incomplete array

This implements the new implicit conversion sequence to an incomplete
(unbounded) array type.  It is mostly Richard Smith's work, updated to
trunk, testcases added and a few bugs fixed found in such testing.

It is not a complete implementation of p0388.

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


  Commit: 444ec0957c58492ecce0569bb20b7d3ad59d37bb
      https://github.com/llvm/llvm-project/commit/444ec0957c58492ecce0569bb20b7d3ad59d37bb
  Author: Nathan Sidwell <nathan at acm.org>
  Date:   2021-10-12 (Tue, 12 Oct 2021)

  Changed paths:
    M clang/include/clang/Sema/Overload.h
    M clang/lib/AST/ASTContext.cpp
    M clang/lib/Sema/SemaOverload.cpp
    M clang/test/SemaCXX/cxx20-p0388-unbound-ary.cpp
    M clang/www/cxx_status.html

  Log Message:
  -----------
  [clang] p0388 array list initialization overloads

This is the second part of p0388, dealing with overloads of list
initialization to incomplete array types.  It extends the handling
added in D103088 to permit incomplete arrays.  We have to record that
the conversion involved an incomplete array, and so (re-add) a bit flag
into the standard conversion sequence object.  Comparing such
conversion sequences requires knowing (a) the number of array elements
initialized and (b) whether the initialization is of an incomplete array.

This also updates the web page to indicate p0388 is implemented (there
is no feature macro).

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


Compare: https://github.com/llvm/llvm-project/compare/a76cfc2e840f...444ec0957c58


More information about the All-commits mailing list