A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/llvm/llvm-project/issues/64717 below:

[libc++] `std::ranges::clamp` violates [alg.clamp]p5 · Issue #64717 · llvm/llvm-project · GitHub

Skip to content Navigation Menu Search code, repositories, users, issues, pull requests...

Saved searches Use saved searches to filter your results more quickly

Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert

[libc++] std::ranges::clamp violates [alg.clamp]p5 #64717

Assignees

Description

[alg.clamp]p5 mandates the complexity requirements for std::ranges::clamp to be at most two comparisons and three applications of the projection. libc++ however applies the projection four times. See godbolt.

if (std::invoke(__comp, std::invoke(__proj, __value), std::invoke(__proj, __low))) return __low; else if (std::invoke(__comp, std::invoke(__proj, __high), std::invoke(__proj, __value))) return __high; Metadata Metadata

Development

No branches or pull requests Issue actions

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4