修改pods
This commit is contained in:
16
Pods/abseil/absl/random/beta_distribution.h
generated
16
Pods/abseil/absl/random/beta_distribution.h
generated
@@ -181,18 +181,18 @@ class beta_distribution {
|
||||
result_type alpha_;
|
||||
result_type beta_;
|
||||
|
||||
result_type a_; // the smaller of {alpha, beta}, or 1.0/alpha_ in JOEHNK
|
||||
result_type b_; // the larger of {alpha, beta}, or 1.0/beta_ in JOEHNK
|
||||
result_type x_; // alpha + beta, or the result in degenerate cases
|
||||
result_type log_x_; // log(x_)
|
||||
result_type y_; // "beta" in Cheng
|
||||
result_type gamma_; // "gamma" in Cheng
|
||||
result_type a_{}; // the smaller of {alpha, beta}, or 1.0/alpha_ in JOEHNK
|
||||
result_type b_{}; // the larger of {alpha, beta}, or 1.0/beta_ in JOEHNK
|
||||
result_type x_{}; // alpha + beta, or the result in degenerate cases
|
||||
result_type log_x_{}; // log(x_)
|
||||
result_type y_{}; // "beta" in Cheng
|
||||
result_type gamma_{}; // "gamma" in Cheng
|
||||
|
||||
Method method_;
|
||||
Method method_{};
|
||||
|
||||
// Placing this last for optimal alignment.
|
||||
// Whether alpha_ != a_, i.e. true iff alpha_ > beta_.
|
||||
bool inverted_;
|
||||
bool inverted_{};
|
||||
|
||||
static_assert(std::is_floating_point<RealType>::value,
|
||||
"Class-template absl::beta_distribution<> must be "
|
||||
|
||||
16
Pods/abseil/absl/random/bit_gen_ref.h
generated
16
Pods/abseil/absl/random/bit_gen_ref.h
generated
@@ -28,6 +28,7 @@
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
#include "absl/base/attributes.h"
|
||||
#include "absl/base/internal/fast_type_id.h"
|
||||
#include "absl/base/macros.h"
|
||||
#include "absl/meta/type_traits.h"
|
||||
@@ -110,20 +111,21 @@ class BitGenRef {
|
||||
BitGenRef& operator=(const BitGenRef&) = default;
|
||||
BitGenRef& operator=(BitGenRef&&) = default;
|
||||
|
||||
template <typename URBG, typename absl::enable_if_t<
|
||||
(!std::is_same<URBG, BitGenRef>::value &&
|
||||
random_internal::is_urbg<URBG>::value &&
|
||||
!HasInvokeMock<URBG>::value)>* = nullptr>
|
||||
BitGenRef(URBG& gen) // NOLINT
|
||||
template <
|
||||
typename URBGRef, typename URBG = absl::remove_cvref_t<URBGRef>,
|
||||
typename absl::enable_if_t<(!std::is_same<URBG, BitGenRef>::value &&
|
||||
random_internal::is_urbg<URBG>::value &&
|
||||
!HasInvokeMock<URBG>::value)>* = nullptr>
|
||||
BitGenRef(URBGRef&& gen ABSL_ATTRIBUTE_LIFETIME_BOUND) // NOLINT
|
||||
: t_erased_gen_ptr_(reinterpret_cast<uintptr_t>(&gen)),
|
||||
mock_call_(NotAMock),
|
||||
generate_impl_fn_(ImplFn<URBG>) {}
|
||||
|
||||
template <typename URBG,
|
||||
template <typename URBGRef, typename URBG = absl::remove_cvref_t<URBGRef>,
|
||||
typename absl::enable_if_t<(!std::is_same<URBG, BitGenRef>::value &&
|
||||
random_internal::is_urbg<URBG>::value &&
|
||||
HasInvokeMock<URBG>::value)>* = nullptr>
|
||||
BitGenRef(URBG& gen) // NOLINT
|
||||
BitGenRef(URBGRef&& gen ABSL_ATTRIBUTE_LIFETIME_BOUND) // NOLINT
|
||||
: t_erased_gen_ptr_(reinterpret_cast<uintptr_t>(&gen)),
|
||||
mock_call_(&MockCall<URBG>),
|
||||
generate_impl_fn_(ImplFn<URBG>) {}
|
||||
|
||||
22
Pods/abseil/absl/random/distributions.h
generated
22
Pods/abseil/absl/random/distributions.h
generated
@@ -32,8 +32,8 @@
|
||||
// continuously and independently at a constant average rate
|
||||
// * `absl::Gaussian` (also known as "normal distributions") for continuous
|
||||
// distributions using an associated quadratic function
|
||||
// * `absl::LogUniform` for continuous uniform distributions where the log
|
||||
// to the given base of all values is uniform
|
||||
// * `absl::LogUniform` for discrete distributions where the log to the given
|
||||
// base of all values is uniform
|
||||
// * `absl::Poisson` for discrete probability distributions that express the
|
||||
// probability of a given number of events occurring within a fixed interval
|
||||
// * `absl::Zipf` for discrete probability distributions commonly used for
|
||||
@@ -46,23 +46,23 @@
|
||||
#ifndef ABSL_RANDOM_DISTRIBUTIONS_H_
|
||||
#define ABSL_RANDOM_DISTRIBUTIONS_H_
|
||||
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
#include <limits>
|
||||
#include <random>
|
||||
#include <type_traits>
|
||||
|
||||
#include "absl/base/config.h"
|
||||
#include "absl/base/internal/inline_variable.h"
|
||||
#include "absl/meta/type_traits.h"
|
||||
#include "absl/random/bernoulli_distribution.h"
|
||||
#include "absl/random/beta_distribution.h"
|
||||
#include "absl/random/exponential_distribution.h"
|
||||
#include "absl/random/gaussian_distribution.h"
|
||||
#include "absl/random/internal/distribution_caller.h" // IWYU pragma: export
|
||||
#include "absl/random/internal/traits.h"
|
||||
#include "absl/random/internal/uniform_helper.h" // IWYU pragma: export
|
||||
#include "absl/random/log_uniform_int_distribution.h"
|
||||
#include "absl/random/poisson_distribution.h"
|
||||
#include "absl/random/uniform_int_distribution.h"
|
||||
#include "absl/random/uniform_real_distribution.h"
|
||||
#include "absl/random/uniform_int_distribution.h" // IWYU pragma: export
|
||||
#include "absl/random/uniform_real_distribution.h" // IWYU pragma: export
|
||||
#include "absl/random/zipf_distribution.h"
|
||||
|
||||
namespace absl {
|
||||
@@ -176,7 +176,7 @@ Uniform(TagType tag,
|
||||
|
||||
return random_internal::DistributionCaller<gen_t>::template Call<
|
||||
distribution_t>(&urbg, tag, static_cast<return_t>(lo),
|
||||
static_cast<return_t>(hi));
|
||||
static_cast<return_t>(hi));
|
||||
}
|
||||
|
||||
// absl::Uniform(bitgen, lo, hi)
|
||||
@@ -200,7 +200,7 @@ Uniform(URBG&& urbg, // NOLINT(runtime/references)
|
||||
|
||||
return random_internal::DistributionCaller<gen_t>::template Call<
|
||||
distribution_t>(&urbg, static_cast<return_t>(lo),
|
||||
static_cast<return_t>(hi));
|
||||
static_cast<return_t>(hi));
|
||||
}
|
||||
|
||||
// absl::Uniform<unsigned T>(bitgen)
|
||||
@@ -208,7 +208,7 @@ Uniform(URBG&& urbg, // NOLINT(runtime/references)
|
||||
// Overload of Uniform() using the minimum and maximum values of a given type
|
||||
// `T` (which must be unsigned), returning a value of type `unsigned T`
|
||||
template <typename R, typename URBG>
|
||||
typename absl::enable_if_t<!std::is_signed<R>::value, R> //
|
||||
typename absl::enable_if_t<!std::numeric_limits<R>::is_signed, R> //
|
||||
Uniform(URBG&& urbg) { // NOLINT(runtime/references)
|
||||
using gen_t = absl::decay_t<URBG>;
|
||||
using distribution_t = random_internal::UniformDistributionWrapper<R>;
|
||||
@@ -362,7 +362,7 @@ RealType Gaussian(URBG&& urbg, // NOLINT(runtime/references)
|
||||
// If `lo` is nonzero then this distribution is shifted to the desired interval,
|
||||
// so LogUniform(lo, hi, b) is equivalent to LogUniform(0, hi-lo, b)+lo.
|
||||
//
|
||||
// See https://en.wikipedia.org/wiki/Log-normal_distribution
|
||||
// See https://en.wikipedia.org/wiki/Reciprocal_distribution
|
||||
//
|
||||
// Example:
|
||||
//
|
||||
|
||||
2
Pods/abseil/absl/random/seed_sequences.h
generated
2
Pods/abseil/absl/random/seed_sequences.h
generated
@@ -29,9 +29,11 @@
|
||||
#include <random>
|
||||
|
||||
#include "absl/base/config.h"
|
||||
#include "absl/base/nullability.h"
|
||||
#include "absl/random/internal/salted_seed_seq.h"
|
||||
#include "absl/random/internal/seed_material.h"
|
||||
#include "absl/random/seed_gen_exception.h"
|
||||
#include "absl/strings/string_view.h"
|
||||
#include "absl/types/span.h"
|
||||
|
||||
namespace absl {
|
||||
|
||||
Reference in New Issue
Block a user