[all-commits] [llvm/llvm-project] b09551: [libc++] Fix implementation of iota_view::size (#6...
Louis Dionne via All-commits
all-commits at lists.llvm.org
Wed Oct 4 15:34:56 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b09551f07408aad37c5be7fdbd8dd5a6f9056738
https://github.com/llvm/llvm-project/commit/b09551f07408aad37c5be7fdbd8dd5a6f9056738
Author: Louis Dionne <ldionne.2 at gmail.com>
Date: 2023-10-04 (Wed, 04 Oct 2023)
Changed paths:
M libcxx/include/__ranges/iota_view.h
M libcxx/test/std/ranges/range.factories/range.iota.view/size.pass.cpp
Log Message:
-----------
[libc++] Fix implementation of iota_view::size (#67819)
We were incorrectly deducing the return type of size() because we were
not using ternary operators in the implementation (as the spec says).
Instead of deducing the common type of the expressions in the spec, we
would deduce potentially different return types and fail to compile.
Fixes #67551
More information about the All-commits
mailing list