Skip to content

Commit 9a5b89d

Browse files
committed
initial checkin
[SVN r14159]
1 parent c12ffa2 commit 9a5b89d

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

include/boost/python/borrowed.hpp

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// Copyright David Abrahams 2002. Permission to copy, use,
2+
// modify, sell and distribute this software is granted provided this
3+
// copyright notice appears in all copies. This software is provided
4+
// "as is" without express or implied warranty, and with no claim as
5+
// to its suitability for any purpose.
6+
#ifndef BORROWED_DWA2002614_HPP
7+
# define BORROWED_DWA2002614_HPP
8+
# include <boost/python/detail/borrowed_ptr.hpp>
9+
10+
namespace boost { namespace python {
11+
12+
template <class T>
13+
inline python::detail::borrowed<T>* borrowed(T* p)
14+
{
15+
return (detail::borrowed<T>*)p;
16+
}
17+
18+
}} // namespace boost::python
19+
20+
#endif // BORROWED_DWA2002614_HPP

0 commit comments

Comments
 (0)