Python bindings - global variables

Consider the following reflected C++ global variables which are defined in namespace 'ns'


// C++ code
namespace ns
{
    $var+ int32 x = 0;
    $var+ string8 s = "hello";
}

These globals can be accessed directly from Python like this:


# python code

ns.x = 10
print 'ns.x = ' + `ns.x`

ns.s = ns.s + " world"
print 'ns.s = ' + `ns.s`