mirror of
https://github.com/boostorg/python.git
synced 2026-01-20 16:52:15 +00:00
18 lines
281 B
C++
18 lines
281 B
C++
// Hello World Example from the tutorial
|
|
// [Joel de Guzman 10/9/2002]
|
|
|
|
char const* greet()
|
|
{
|
|
return "hello, world";
|
|
}
|
|
|
|
#include <boost/python/module.hpp>
|
|
#include <boost/python/def.hpp>
|
|
using namespace boost::python;
|
|
|
|
BOOST_PYTHON_MODULE(hello)
|
|
{
|
|
def("greet", greet);
|
|
}
|
|
|