[all-commits] [llvm/llvm-project] 65a1ef: Fixed shared_ptr comparisons with nullptr_t when s...

James Touton via All-commits all-commits at lists.llvm.org
Tue Jan 9 11:41:37 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 65a1efc60ca390cb68409fd27d5648b4caa6cb54
      https://github.com/llvm/llvm-project/commit/65a1efc60ca390cb68409fd27d5648b4caa6cb54
  Author: James Touton <bekenn at gmail.com>
  Date:   2024-01-09 (Tue, 09 Jan 2024)

  Changed paths:
    M libcxx/include/__memory/shared_ptr.h
    M libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.cmp/cmp_nullptr.pass.cpp
    M libcxx/test/std/utilities/smartptr/unique.ptr/unique.ptr.special/cmp_nullptr.pass.cpp

  Log Message:
  -----------
  Fixed shared_ptr comparisons with nullptr_t when spaceship is unavailable. (#76781)

This was causing compilation errors when attempting to compare a
`shared_ptr<T[]>` with `nullptr`, as `get()` returns `T*` rather than `T
(*)[]`. `unique_ptr` did not have this issue, but I've added tests to
make sure.




More information about the All-commits mailing list