v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
functional.h
Go to the documentation of this file.
1
// Copyright 2024 the V8 project authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#ifndef V8_BASE_TEMPLATE_META_PROGRAMMING_FUNCTIONAL_H_
6
#define V8_BASE_TEMPLATE_META_PROGRAMMING_FUNCTIONAL_H_
7
8
#include "
src/base/template-meta-programming/list.h
"
9
10
namespace
v8::base::tmp
{
11
12
template
<
typename
T>
13
struct
lazy_false
: std::false_type {};
14
template
<
typename
T>
15
struct
lazy_true
: std::true_type {};
16
17
// call_parameters returns a list of parameter types of the given (member)
18
// function pointer.
19
template
<
typename
>
20
struct
call_parameters
;
21
template
<
typename
R,
typename
... Args>
22
struct
call_parameters
<R (*)(Args...)> {
23
using
type
=
list
<Args...>;
24
};
25
template
<
typename
R,
typename
O,
typename
... Args>
26
struct
call_parameters
<R (O::*)(Args...)> {
27
using
type
=
list
<Args...>;
28
};
29
template
<
typename
T>
30
using
call_parameters_t
=
typename
call_parameters<T>::type
;
31
32
}
// namespace v8::base::tmp
33
34
#endif
// V8_BASE_TEMPLATE_META_PROGRAMMING_FUNCTIONAL_H_
list.h
v8::base::tmp
Definition
common.h:14
v8::base::tmp::call_parameters_t
typename call_parameters< T >::type call_parameters_t
Definition
functional.h:30
v8::base::tmp::call_parameters
Definition
functional.h:20
v8::base::tmp::lazy_false
Definition
functional.h:13
v8::base::tmp::lazy_true
Definition
functional.h:15
v8::base::tmp::list
Definition
list.h:22
src
base
template-meta-programming
functional.h
Generated on Sun Apr 6 2025 21:08:50 for v8 by
1.12.0