//===----------------------------------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// // REQUIRES: std-at-least-c++23 // // constexpr decltype(auto) operator*() const; #include #include #include #include #include #include #include #include #include #include "../types.h" struct ProxyRef { int& val; }; class CommonProxyRef { public: constexpr CommonProxyRef(ProxyRef i) : val(i.val) {} constexpr CommonProxyRef(int i) : val(i) {} constexpr int get() const { return val; } private: int val; }; template