[all-commits] [llvm/llvm-project] 347d4d: [ADT] Fix Optional<> with llvm::is_trivially_move_...

Steven Wu via All-commits all-commits at lists.llvm.org
Tue Jan 18 08:38:00 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 347d4d7323c4cf0d89fb14530e27ec5e2b1afeda
      https://github.com/llvm/llvm-project/commit/347d4d7323c4cf0d89fb14530e27ec5e2b1afeda
  Author: Steven Wu <stevenwu at apple.com>
  Date:   2022-01-18 (Tue, 18 Jan 2022)

  Changed paths:
    M llvm/include/llvm/ADT/Optional.h
    M llvm/unittests/ADT/OptionalTest.cpp

  Log Message:
  -----------
  [ADT] Fix Optional<> with llvm::is_trivially_move_constructible

Fix the compatibility of Optional<> with some GCC versions that it will fail
to compile when T is getting checked for `is_trivially_move_constructible`
as mentioned here: https://reviews.llvm.org/D93510#2538983

Fix the problem by using `llvm::is_trivially_move_constructible`.

Reviewed By: jplayer-nv, tatyana-krasnukha

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




More information about the All-commits mailing list