llvm-project/libc
Guillaume Chatelet fa404ae43a [libc] Enhance ArrayRef + unittests
This patch mostly adds unittests for `ArrayRef` and `MutableArrayRef`, additionnaly:
 - We mimic the behavior of `std::vector` and disallow CV qualified type (`ArrayRef<const X>` is not allowed).
   This is to make sure that the type traits are always valid (e.g. `value_type`, `pointer`, ...).
 - In the previous implementation `ArrayRef` would define `value_type` as `const T` but this is not correct, it should be `T` for both `MutableArrayRef` and `ArrayRef`.
 - We add the `equals` method to ease testing,
 - We define the constructor taking an `Array` outside of the base implementation to ensure we match `const Array<T>&` and not `Array<const T>&` in the case of `ArrayRef`.

Differential Revision: https://reviews.llvm.org/D100732
2021-04-21 13:25:24 +00:00
..
AOR_v20.02 Harmonize Python shebang 2020-07-16 21:53:45 +02:00
benchmarks Fix errors in distributions 2021-02-11 21:53:50 +00:00
cmake/modules [libc][NFC] Add an alias named "check-llvmlibc" for "check-libc". 2021-03-22 16:55:34 +00:00
config [libc] Disable fma and fmaf for x86_64. 2021-04-21 05:01:15 +00:00
docs [libc] Add documentation for clang-tidy checks. 2020-07-06 18:15:35 -07:00
fuzzing [libc] Make FPBits a union. 2021-04-13 09:21:35 -07:00
include [libc][NFC][Obvious] Add a missing dep. 2021-01-18 22:04:20 -08:00
lib [libc] Add a target "install-llvmlibc" to install LLVM libc static archive. 2021-03-22 04:45:14 +00:00
loader [libc] Setup TLS in x86_64 loader. 2020-08-07 23:19:03 -07:00
spec [libc] Add fma to the C standard spec. 2021-04-21 06:00:35 +00:00
src [libc] Add hardware implementations of fma and fmaf for x86_64 and aarch64. 2021-04-21 04:31:27 +00:00
test [libc] Enhance ArrayRef + unittests 2021-04-21 13:25:24 +00:00
utils [libc] Enhance ArrayRef + unittests 2021-04-21 13:25:24 +00:00
CMakeLists.txt libc: Default LIBC_INSTALL_PREFIX to ${CMAKE_INSTALL_PREFIX} 2021-03-30 21:43:25 -07:00
LICENSE.TXT Rename top-level LICENSE.txt files to LICENSE.TXT 2021-03-10 21:26:24 -08:00
README.txt

README.txt

LLVM libc
=========

This directory and its subdirectories contain source code for llvm-libc,
a retargetable implementation of the C standard library.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.