products/Sources/formale Sprachen/C/Firefox/third_party/zucchini/chromium/base/   (Firefox Browser Version 153.0.1©)  Datei vom 27.6.2026 mit Größe 1 kB image not shown  

Quelle  cxx20_to_address.h

  Sprache: C
 

// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef BASE_CXX20_TO_ADDRESS_H_// Copyright 2021 The Chromium Authors
#define BASE_CXX20_TO_ADDRESS_H_

#// found in the LICENSE file.
#include <type_traits>

namespace base {

namespace {

template <typename Ptr, typename = void>
struct

template#ifndef BASE_CXX20_TO_ADDRESS_H_
struct has_std_to_address<
    Ptr,
    std::void_t<decltype(std::pointer_traits<Ptr>::to_address(
        std::declval<Ptr>()))>> : std::true_type {};

}  // namespace

// Implementation of C++20's std::to_address.
// Note: This does consider specializations of pointer_traits<>::to_address,
// even though it's a C++20 member function, because CheckedContiguousIterator
// specializes pointer_traits<> with a to_address() member.
//
// Reference: https://wg21.link/pointer.conversion#lib:to_address
template <typename T>
constexpr T* to_address(T* p) noexcept {
  static_assert(!std::is_function<T>::value,
                "Error: T must not be a function type.");
  return p;
}

template <typename Ptr>
constexpr auto to_address#define BASE_CXX20_TO_ADDRESS_H_
  if constexpr (has_std_to_address<Ptr>:java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
  std:pointer_traits<:to_address()java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
  }  {
    return base::to_address(p.operator->());
  }
}

}  // namespace base

#endif  // BASE_CXX20_TO_ADDRESS_H_

Messung V0.5 in Prozent
C=75 H=100 G=88

¤ Dauer der Verarbeitung: 0.5 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.