[all-commits] [llvm/llvm-project] 2eadbc: [libc++] Rework the whole availability markup impl...

Louis Dionne via All-commits all-commits at lists.llvm.org
Thu Nov 5 09:29:12 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 2eadbc86142bab5b46dfeb55d8bd6724234278bb
      https://github.com/llvm/llvm-project/commit/2eadbc86142bab5b46dfeb55d8bd6724234278bb
  Author: Louis Dionne <ldionne at apple.com>
  Date:   2020-11-05 (Thu, 05 Nov 2020)

  Changed paths:
    M libcxx/CMakeLists.txt
    M libcxx/cmake/caches/Apple.cmake
    R libcxx/docs/DesignDocs/AvailabilityMarkup.rst
    M libcxx/include/CMakeLists.txt
    A libcxx/include/__availability
    M libcxx/include/__config
    M libcxx/include/__config_site.in
    M libcxx/include/__locale
    M libcxx/include/__threading_support
    M libcxx/include/any
    M libcxx/include/atomic
    M libcxx/include/barrier
    M libcxx/include/charconv
    M libcxx/include/chrono
    M libcxx/include/exception
    M libcxx/include/filesystem
    M libcxx/include/fstream
    M libcxx/include/future
    M libcxx/include/latch
    M libcxx/include/memory
    M libcxx/include/new
    M libcxx/include/optional
    M libcxx/include/semaphore
    M libcxx/include/shared_mutex
    M libcxx/include/typeinfo
    M libcxx/include/variant
    M libcxx/src/optional.cpp
    M libcxx/utils/libcxx/test/features.py
    M libcxx/utils/libcxx/test/params.py

  Log Message:
  -----------
  [libc++] Rework the whole availability markup implementation

Currently, vendor-specific availability markup is enabled by default.
This means that even when building against trunk libc++, the headers
will by default prevent you from using some features that were not
released in the dylib on your target platform. This is a source of
frustration since people building libc++ from sources are usually not
trying to use some vendor's released dylib.

For that reason, I've been thinking for a long time that availability
annotations should be off by default, which is the primary change that
this commit enables.

In addition, it reworks the implementation to make it easier for new
vendors to add availability annotations for their platform, and it
refreshes the documentation to reflect the current state of the codebase.

Finally, a CMake configuration option is added to control whether
availability annotations should be turned on for the flavor of libc++
being created. The intent is for vendors like Apple to turn it on, and
for the upstream libc++ to leave it off (the default).

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




More information about the All-commits mailing list