Mercurial > pytave
comparison pyexec.cc @ 406:16e79a1e96b8
Eliminate all remaining uses of "using namespace"
* octave_to_python.cc, pycall.cc, pyeval.cc, pyexec.cc, python_to_octave.cc:
Eliminate all remaining uses of "using namespace", use fully qualified class
and function names from Boost.
author | Mike Miller <mtmiller@octave.org> |
---|---|
date | Mon, 01 May 2017 08:41:01 -0700 |
parents | 478d83448b0b |
children | 95c6ad0be828 |
comparison
equal
deleted
inserted
replaced
405:478d83448b0b | 406:16e79a1e96b8 |
---|---|
33 #include "exceptions.h" | 33 #include "exceptions.h" |
34 #include "oct-py-eval.h" | 34 #include "oct-py-eval.h" |
35 #include "oct-py-init.h" | 35 #include "oct-py-init.h" |
36 #include "oct-py-util.h" | 36 #include "oct-py-util.h" |
37 #include "python_to_octave.h" | 37 #include "python_to_octave.h" |
38 | |
39 using namespace boost::python; | |
40 | 38 |
41 DEFUN_DLD (pyexec, args, nargout, | 39 DEFUN_DLD (pyexec, args, nargout, |
42 "-*- texinfo -*-\n\ | 40 "-*- texinfo -*-\n\ |
43 @deftypefn {} {} pyexec (@var{expr})\n\ | 41 @deftypefn {} {} pyexec (@var{expr})\n\ |
44 @deftypefnx {} {} pyexec (@var{expr}, @var{localns})\n\ | 42 @deftypefnx {} {} pyexec (@var{expr}, @var{localns})\n\ |
88 } | 86 } |
89 catch (pytave::object_convert_exception const &) | 87 catch (pytave::object_convert_exception const &) |
90 { | 88 { |
91 error ("pyexec: error in return value type conversion"); | 89 error ("pyexec: error in return value type conversion"); |
92 } | 90 } |
93 catch (error_already_set const &) | 91 catch (boost::python::error_already_set const &) |
94 { | 92 { |
95 std::string message = pytave::fetch_exception_message (); | 93 std::string message = pytave::fetch_exception_message (); |
96 error ("pyexec: %s", message.c_str ()); | 94 error ("pyexec: %s", message.c_str ()); |
97 } | 95 } |
98 return retval; | 96 return retval; |