From 9244a27f9548a1d39fb01348fde66ff81f5150a4 Mon Sep 17 00:00:00 2001 From: Alexis Hildebrandt Date: Wed, 12 Apr 2023 20:33:40 +0200 Subject: Refactor python related types into ledger::python namespace --- src/pyutils.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/pyutils.h') diff --git a/src/pyutils.h b/src/pyutils.h index aa9c4451..c02be37b 100644 --- a/src/pyutils.h +++ b/src/pyutils.h @@ -39,6 +39,8 @@ */ #pragma once +namespace ledger { namespace python { + template struct object_from_python { @@ -142,6 +144,8 @@ PyObject * str_to_py_unicode(const T& str) return object(handle<>(borrowed(uni))).ptr(); } +} } // namespace ledger::python + namespace boost { namespace python { // Use expr to create the PyObject corresponding to x @@ -178,7 +182,7 @@ namespace boost { namespace python { : handle<> \ { \ arg_to_python(T const& x) \ - : python::handle<>(expr) {} \ + : boost::python::handle<>(expr) {} \ }; \ } -- cgit v1.2.3