mirror of
https://github.com/pybind/pybind11.git
synced 2026-04-20 06:49:25 +00:00
* Factor out pybind11/detail/pybind11_namespace_macros.h from pybind11/detail/common.h * Eliminate `pybindit` namespace, use pybind11/detail/pybind11_namespace_macros.h instead. * Fix oversight: add pybind11_namespace_macros.h in tests/extra_python_package/test_files.py * [skip ci] Add copyright notice.
23 lines
540 B
C++
23 lines
540 B
C++
// Copyright (c) 2024 The Pybind Development Team.
|
|
// All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
#pragma once
|
|
|
|
#include "common.h"
|
|
#include "struct_smart_holder.h"
|
|
|
|
#include <type_traits>
|
|
|
|
PYBIND11_NAMESPACE_BEGIN(PYBIND11_NAMESPACE)
|
|
|
|
using pybind11::memory::smart_holder;
|
|
|
|
PYBIND11_NAMESPACE_BEGIN(detail)
|
|
|
|
template <typename H>
|
|
using is_smart_holder = std::is_same<H, smart_holder>;
|
|
|
|
PYBIND11_NAMESPACE_END(detail)
|
|
PYBIND11_NAMESPACE_END(PYBIND11_NAMESPACE)
|