Skip to content

Commit 64157f2

Browse files
committed
fix: fully qualify all usages of concat
Signed-off-by: Henry Schreiner <[email protected]>
1 parent bade99c commit 64157f2

File tree

5 files changed

+14
-10
lines changed

5 files changed

+14
-10
lines changed

include/pybind11/eigen/tensor.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ struct eigen_tensor_helper<Eigen::Tensor<Scalar_, NumIndices_, Options_, IndexTy
7070

7171
template <size_t... Is>
7272
struct helper<index_sequence<Is...>> {
73-
static constexpr auto value = concat(const_name(((void) Is, "?"))...);
73+
static constexpr auto value = ::pybind11::detail::concat(const_name(((void) Is, "?"))...);
7474
};
7575

7676
static constexpr auto dimensions_descriptor
@@ -104,7 +104,8 @@ struct eigen_tensor_helper<
104104
return get_shape() == shape;
105105
}
106106

107-
static constexpr auto dimensions_descriptor = concat(const_name<Indices>()...);
107+
static constexpr auto dimensions_descriptor
108+
= ::pybind11::detail::concat(const_name<Indices>()...);
108109

109110
template <typename... Args>
110111
static Type *alloc(Args &&...args) {

include/pybind11/functional.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,8 @@ struct type_caster<std::function<Return(Args...)>> {
128128
}
129129

130130
PYBIND11_TYPE_CASTER(type,
131-
const_name("Callable[[") + concat(make_caster<Args>::name...)
131+
const_name("Callable[[")
132+
+ ::pybind11::detail::concat(make_caster<Args>::name...)
132133
+ const_name("], ") + make_caster<retval_type>::name
133134
+ const_name("]"));
134135
};

include/pybind11/numpy.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ struct array_info<std::array<T, N>> {
371371
}
372372

373373
static constexpr auto extents = const_name<array_info<T>::is_array>(
374-
concat(const_name<N>(), array_info<T>::extents), const_name<N>());
374+
::pybind11::detail::concat(const_name<N>(), array_info<T>::extents), const_name<N>());
375375
};
376376
// For numpy we have special handling for arrays of characters, so we don't include
377377
// the size in the array extents.

include/pybind11/stl.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,8 @@ struct variant_caster<V<Ts...>> {
421421

422422
using Type = V<Ts...>;
423423
PYBIND11_TYPE_CASTER(Type,
424-
const_name("Union[") + detail::concat(make_caster<Ts>::name...)
424+
const_name("Union[")
425+
+ ::pybind11::detail::concat(make_caster<Ts>::name...)
425426
+ const_name("]"));
426427
};
427428

include/pybind11/typing.h

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,9 @@ PYBIND11_NAMESPACE_BEGIN(detail)
6969

7070
template <typename... Types>
7171
struct handle_type_name<typing::Tuple<Types...>> {
72-
static constexpr auto name
73-
= const_name("tuple[") + concat(make_caster<Types>::name...) + const_name("]");
72+
static constexpr auto name = const_name("tuple[")
73+
+ ::pybind11::detail::concat(make_caster<Types>::name...)
74+
+ const_name("]");
7475
};
7576

7677
template <>
@@ -108,9 +109,9 @@ struct handle_type_name<typing::Iterator<T>> {
108109
template <typename Return, typename... Args>
109110
struct handle_type_name<typing::Callable<Return(Args...)>> {
110111
using retval_type = conditional_t<std::is_same<Return, void>::value, void_type, Return>;
111-
static constexpr auto name = const_name("Callable[[") + concat(make_caster<Args>::name...)
112-
+ const_name("], ") + make_caster<retval_type>::name
113-
+ const_name("]");
112+
static constexpr auto name
113+
= const_name("Callable[[") + ::pybind11::detail::concat(make_caster<Args>::name...)
114+
+ const_name("], ") + make_caster<retval_type>::name + const_name("]");
114115
};
115116

116117
PYBIND11_NAMESPACE_END(detail)

0 commit comments

Comments
 (0)