// Make a new function declaration. Function_decl* make_function_decl(Location loc, String const* n, Decl_seq const& p, Type const* r, Stmt const* s) { Input_context cxt(loc); if (!check_definition(r, s)) return make_error_node<Function_decl>(); return new Function_decl(loc, n, get_function_type(p, r), p, s); }
Decl* Parser::on_method(Specifier spec, Token tok, Decl_seq const& p, Type const* t, Stmt* b) { Type const* f = get_function_type(p, t); Decl* decl = new Method_decl(tok.symbol(), f, p, b); locate(decl, tok.location()); return decl; }
// Elaborate each type in the function type. Type const* Elaborator::elaborate(Function_type const* t) { Type_seq ts; ts.reserve(t->parameter_types().size()); for (Type const* t1 : t->parameter_types()) ts.push_back(elaborate(t1)); Type const* r = elaborate(t->return_type()); return get_function_type(ts, r); }
Function_type& Builder::get_function_type(Decl_list const& ps, Type& r) { Type_list ts; for (Decl& d : *modify(&ps)) { Object_parm& p = cast<Object_parm>(d); ts.push_back(p.type()); } return get_function_type(ts, r); }
/* * Load one action attribute. */ static int get_action_attribute( FILE * inFile, ABObj obj, ABObj module, ABObj action, AB_GIL_ATTRIBUTE attr ) { int return_value = 0; int rc = 0; /* r turn code */ if (abio_get_eof(inFile)) { return (abil_print_load_err(ERR_EOF), -1); } switch (attr) { case AB_GIL_FROM: rc = get_from(inFile, obj, module, action); break; case AB_GIL_ACTION: rc = get_operation(inFile, action); break; case AB_GIL_TO: rc = get_to(inFile, obj, module, action); break; case AB_GIL_WHEN: rc = get_when(inFile, obj, action); break; case AB_GIL_FUNCTION_TYPE: rc = get_function_type(inFile, action); break; case AB_GIL_ARG_TYPE: rc = get_arg_type(inFile, action); break; default: abil_print_load_err(ERR_UNKNOWN); } return return_value; }
static void set_decl_codes(struct decl_hash *decl_hash_data) { const_tree arg, type; enum tree_code code; if (TREE_CODE(decl_hash_data->decl) == VAR_DECL || TREE_CODE(decl_hash_data->decl) == FIELD_DECL) { set_based_decl_codes(TREE_TYPE(decl_hash_data->decl), decl_hash_data); return; } type = get_function_type(decl_hash_data->decl); code = TREE_CODE(type); gcc_assert(code == FUNCTION_TYPE || code == METHOD_TYPE); if (FUNCTION_PTR_P(decl_hash_data->decl)) set_result_codes(type, decl_hash_data); else set_result_codes(decl_hash_data->decl, decl_hash_data); for (arg = TYPE_ARG_TYPES(type); arg != NULL_TREE && decl_hash_data->tree_codes_len < CODES_LIMIT; arg = TREE_CHAIN(arg)) set_based_decl_codes(TREE_VALUE(arg), decl_hash_data); }
Decl* Parser::on_function(Specifier spec, Token tok, Decl_seq const& p, Type const* t, Stmt* b) { Type const* f = get_function_type(p, t); return new Function_decl(tok.symbol(), f, p, b); }
Type const* Parser::on_function_type(Type_seq const& ts, Type const* t) { return get_function_type(ts, t); }
void register_Quat_class(){ { //::osg::Quat typedef bp::class_< osg::Quat > Quat_exposer_t; Quat_exposer_t Quat_exposer = Quat_exposer_t( "Quat", "\n A quaternion class. It can be used to represent an orientation in 3D space.\n", bp::init< >() ); bp::scope Quat_scope( Quat_exposer ); Quat_exposer.def( bp::init< double, double, double, double >(( bp::arg("x"), bp::arg("y"), bp::arg("z"), bp::arg("w") )) ); Quat_exposer.def( bp::init< osg::Vec4f const & >(( bp::arg("v") )) ); bp::implicitly_convertible< osg::Vec4f const &, osg::Quat >(); Quat_exposer.def( bp::init< osg::Vec4d const & >(( bp::arg("v") )) ); bp::implicitly_convertible< osg::Vec4d const &, osg::Quat >(); Quat_exposer.def( bp::init< double, osg::Vec3f const & >(( bp::arg("angle"), bp::arg("axis") )) ); Quat_exposer.def( bp::init< double, osg::Vec3d const & >(( bp::arg("angle"), bp::arg("axis") )) ); Quat_exposer.def( bp::init< double, osg::Vec3f const &, double, osg::Vec3f const &, double, osg::Vec3f const & >(( bp::arg("angle1"), bp::arg("axis1"), bp::arg("angle2"), bp::arg("axis2"), bp::arg("angle3"), bp::arg("axis3") )) ); Quat_exposer.def( bp::init< double, osg::Vec3d const &, double, osg::Vec3d const &, double, osg::Vec3d const & >(( bp::arg("angle1"), bp::arg("axis1"), bp::arg("angle2"), bp::arg("axis2"), bp::arg("angle3"), bp::arg("axis3") )) ); { //::osg::Quat::asVec3 typedef ::osg::Vec3d ( ::osg::Quat::*asVec3_function_type )( ) const; Quat_exposer.def( "asVec3" , asVec3_function_type( &::osg::Quat::asVec3 ) ); } { //::osg::Quat::asVec4 typedef ::osg::Vec4d ( ::osg::Quat::*asVec4_function_type )( ) const; Quat_exposer.def( "asVec4" , asVec4_function_type( &::osg::Quat::asVec4 ) ); } { //::osg::Quat::conj typedef ::osg::Quat ( ::osg::Quat::*conj_function_type )( ) const; Quat_exposer.def( "conj" , conj_function_type( &::osg::Quat::conj ) , "\n Conjugate\n" ); } { //::osg::Quat::get typedef void ( ::osg::Quat::*get_function_type )( ::osg::Matrixf & ) const; Quat_exposer.def( "get" , get_function_type( &::osg::Quat::get ) , ( bp::arg("matrix") ) ); } { //::osg::Quat::get typedef void ( ::osg::Quat::*get_function_type )( ::osg::Matrixd & ) const; Quat_exposer.def( "get" , get_function_type( &::osg::Quat::get ) , ( bp::arg("matrix") ) ); } { //::osg::Quat::getRotate typedef boost::python::tuple ( *getRotate_function_type )( ::osg::Quat const & ); Quat_exposer.def( "getRotate" , getRotate_function_type( &getRotate_7cd433cce0eabe855a9b774688d2845e ) , ( bp::arg("inst") ) , " Return the angle and vector represented by the quaternion." ); } { //::osg::Quat::inverse typedef ::osg::Quat const ( ::osg::Quat::*inverse_function_type )( ) const; Quat_exposer.def( "inverse" , inverse_function_type( &::osg::Quat::inverse ) , "\n Multiplicative inverse method: q^(-1) = q^*/(q.q^*)\n" ); } { //::osg::Quat::length typedef double ( ::osg::Quat::*length_function_type )( ) const; Quat_exposer.def( "length" , length_function_type( &::osg::Quat::length ) , "\n Length of the quaternion = sqrt( vec . vec )\n" ); } { //::osg::Quat::length2 typedef double ( ::osg::Quat::*length2_function_type )( ) const; Quat_exposer.def( "length2" , length2_function_type( &::osg::Quat::length2 ) , "\n Length of the quaternion = vec . vec\n" ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( double,double,double,double ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("angle"), bp::arg("x"), bp::arg("y"), bp::arg("z") ) ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( double,::osg::Vec3f const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("angle"), bp::arg("vec") ) ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( double,::osg::Vec3d const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("angle"), bp::arg("vec") ) ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( double,::osg::Vec3f const &,double,::osg::Vec3f const &,double,::osg::Vec3f const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("angle1"), bp::arg("axis1"), bp::arg("angle2"), bp::arg("axis2"), bp::arg("angle3"), bp::arg("axis3") ) ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( double,::osg::Vec3d const &,double,::osg::Vec3d const &,double,::osg::Vec3d const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("angle1"), bp::arg("axis1"), bp::arg("angle2"), bp::arg("axis2"), bp::arg("angle3"), bp::arg("axis3") ) ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( ::osg::Vec3f const &,::osg::Vec3f const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("vec1"), bp::arg("vec2") ) , "\n Make a rotation Quat which will rotate vec1 to vec2.\n Generally take a dot product to get the angle between these\n and then use a cross product to get the rotation axis\n Watch out for the two special cases when the vectors\n are co-incident or opposite in direction.\n" ); } { //::osg::Quat::makeRotate typedef void ( ::osg::Quat::*makeRotate_function_type )( ::osg::Vec3d const &,::osg::Vec3d const & ) ; Quat_exposer.def( "makeRotate" , makeRotate_function_type( &::osg::Quat::makeRotate ) , ( bp::arg("vec1"), bp::arg("vec2") ) , "\n Make a rotation Quat which will rotate vec1 to vec2.\n Generally take a dot product to get the angle between these\n and then use a cross product to get the rotation axis\n Watch out for the two special cases of when the vectors\n are co-incident or opposite in direction.\n" ); } { //::osg::Quat::makeRotate_original typedef void ( ::osg::Quat::*makeRotate_original_function_type )( ::osg::Vec3d const &,::osg::Vec3d const & ) ; Quat_exposer.def( "makeRotate_original" , makeRotate_original_function_type( &::osg::Quat::makeRotate_original ) , ( bp::arg("vec1"), bp::arg("vec2") ) ); } Quat_exposer.def( bp::self != bp::self ); Quat_exposer.def( bp::self * bp::other< double >() ); Quat_exposer.def( bp::self * bp::self ); Quat_exposer.def( bp::self * bp::other< osg::Vec3f >() ); Quat_exposer.def( bp::self * bp::other< osg::Vec3d >() ); Quat_exposer.def( bp::self *= bp::other< double >() ); Quat_exposer.def( bp::self *= bp::self ); Quat_exposer.def( bp::self + bp::self ); Quat_exposer.def( bp::self += bp::self ); Quat_exposer.def( bp::self - bp::self ); Quat_exposer.def( -bp::self ); Quat_exposer.def( bp::self -= bp::self ); Quat_exposer.def( bp::self / bp::other< double >() ); Quat_exposer.def( bp::self / bp::self ); Quat_exposer.def( bp::self /= bp::other< double >() ); Quat_exposer.def( bp::self /= bp::self ); Quat_exposer.def( bp::self < bp::self ); { //::osg::Quat::operator= typedef ::osg::Quat & ( ::osg::Quat::*assign_function_type )( ::osg::Quat const & ) ; Quat_exposer.def( "assign" , assign_function_type( &::osg::Quat::operator= ) , ( bp::arg("v") ) , bp::return_self< >() ); } Quat_exposer.def( bp::self == bp::self ); { //::osg::Quat::operator[] typedef double & ( ::osg::Quat::*__getitem___function_type )( int ) ; Quat_exposer.def( "__getitem__" , __getitem___function_type( &::osg::Quat::operator[] ) , ( bp::arg("i") ) , bp::return_value_policy< bp::copy_non_const_reference >() ); } { //::osg::Quat::operator[] typedef double ( ::osg::Quat::*__getitem___function_type )( int ) const; Quat_exposer.def( "__getitem__" , __getitem___function_type( &::osg::Quat::operator[] ) , ( bp::arg("i") ) ); } { //::osg::Quat::set typedef void ( ::osg::Quat::*set_function_type )( double,double,double,double ) ; Quat_exposer.def( "set" , set_function_type( &::osg::Quat::set ) , ( bp::arg("x"), bp::arg("y"), bp::arg("z"), bp::arg("w") ) ); } { //::osg::Quat::set typedef void ( ::osg::Quat::*set_function_type )( ::osg::Vec4f const & ) ; Quat_exposer.def( "set" , set_function_type( &::osg::Quat::set ) , ( bp::arg("v") ) ); } { //::osg::Quat::set typedef void ( ::osg::Quat::*set_function_type )( ::osg::Vec4d const & ) ; Quat_exposer.def( "set" , set_function_type( &::osg::Quat::set ) , ( bp::arg("v") ) ); } { //::osg::Quat::set typedef void ( ::osg::Quat::*set_function_type )( ::osg::Matrixf const & ) ; Quat_exposer.def( "set" , set_function_type( &::osg::Quat::set ) , ( bp::arg("matrix") ) ); } { //::osg::Quat::set typedef void ( ::osg::Quat::*set_function_type )( ::osg::Matrixd const & ) ; Quat_exposer.def( "set" , set_function_type( &::osg::Quat::set ) , ( bp::arg("matrix") ) ); } { //::osg::Quat::slerp typedef void ( ::osg::Quat::*slerp_function_type )( double,::osg::Quat const &,::osg::Quat const & ) ; Quat_exposer.def( "slerp" , slerp_function_type( &::osg::Quat::slerp ) , ( bp::arg("t"), bp::arg("from"), bp::arg("to") ) , "\n Spherical Linear Interpolation.\n As t goes from 0 to 1, the Quat object goes from from to to.\n" ); } { //::osg::Quat::w typedef double & ( ::osg::Quat::*w_function_type )( ) ; Quat_exposer.def( "w" , w_function_type( &::osg::Quat::w ) , bp::return_value_policy< bp::copy_non_const_reference >() ); } { //::osg::Quat::w typedef double ( ::osg::Quat::*w_function_type )( ) const; Quat_exposer.def( "w" , w_function_type( &::osg::Quat::w ) ); } { //::osg::Quat::x typedef double & ( ::osg::Quat::*x_function_type )( ) ; Quat_exposer.def( "x" , x_function_type( &::osg::Quat::x ) , bp::return_value_policy< bp::copy_non_const_reference >() ); } { //::osg::Quat::x typedef double ( ::osg::Quat::*x_function_type )( ) const; Quat_exposer.def( "x" , x_function_type( &::osg::Quat::x ) ); } { //::osg::Quat::y typedef double & ( ::osg::Quat::*y_function_type )( ) ; Quat_exposer.def( "y" , y_function_type( &::osg::Quat::y ) , bp::return_value_policy< bp::copy_non_const_reference >() ); } { //::osg::Quat::y typedef double ( ::osg::Quat::*y_function_type )( ) const; Quat_exposer.def( "y" , y_function_type( &::osg::Quat::y ) ); } { //::osg::Quat::z typedef double & ( ::osg::Quat::*z_function_type )( ) ; Quat_exposer.def( "z" , z_function_type( &::osg::Quat::z ) , bp::return_value_policy< bp::copy_non_const_reference >() ); } { //::osg::Quat::z typedef double ( ::osg::Quat::*z_function_type )( ) const; Quat_exposer.def( "z" , z_function_type( &::osg::Quat::z ) ); } { //::osg::Quat::zeroRotation typedef bool ( ::osg::Quat::*zeroRotation_function_type )( ) const; Quat_exposer.def( "zeroRotation" , zeroRotation_function_type( &::osg::Quat::zeroRotation ) , "\n return true if the Quat represents a zero rotation, and therefore can be ignored in computations.\n" ); } Quat_exposer.def( bp::self_ns::str( bp::self ) ); Quat_exposer.def( bp::self_ns::str(bp::self) ); Quat_exposer.def(bp::indexing::container_suite< osg::Quat, bp::indexing::all_methods, OsgVec_algorithms<osg::Quat, osg::Quat::value_type, 4> >()); } }
void register_State_class(){ { //::ompl::base::ScopedState< ompl::base::StateSpace > typedef bp::class_< ompl::base::ScopedState< ompl::base::StateSpace > > State_exposer_t; State_exposer_t State_exposer = State_exposer_t( "State", bp::init< boost::shared_ptr< ompl::base::SpaceInformation > const & >(( bp::arg("si") )) ); bp::scope State_scope( State_exposer ); bp::implicitly_convertible< boost::shared_ptr< ompl::base::SpaceInformation > const &, ompl::base::ScopedState< ompl::base::StateSpace > >(); State_exposer.def( bp::init< boost::shared_ptr< ompl::base::StateSpace > const & >(( bp::arg("space") )) ); bp::implicitly_convertible< boost::shared_ptr< ompl::base::StateSpace > const &, ompl::base::ScopedState< ompl::base::StateSpace > >(); State_exposer.def( bp::init< ompl::base::ScopedState< ompl::base::StateSpace > const & >(( bp::arg("other") )) ); State_exposer.def( bp::init< boost::shared_ptr< ompl::base::StateSpace > const &, ompl::base::State const * >(( bp::arg("space"), bp::arg("state") )) ); { //::ompl::base::ScopedState< ompl::base::StateSpace >::distance typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef double ( exported_class_t::*distance_function_type)( ::ompl::base::State const * ) const; State_exposer.def( "distance" , distance_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::distance ) , ( bp::arg("state") ) ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::enforceBounds typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef void ( exported_class_t::*enforceBounds_function_type)( ) ; State_exposer.def( "enforceBounds" , enforceBounds_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::enforceBounds ) ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::get typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::State * ( exported_class_t::*get_function_type)( ) ; State_exposer.def( "get" , get_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::get ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::get typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::State const * ( exported_class_t::*get_function_type)( ) const; State_exposer.def( "get" , get_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::get ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::getSpace typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::boost::shared_ptr< ompl::base::StateSpace > const & ( exported_class_t::*getSpace_function_type)( ) const; State_exposer.def( "getSpace" , getSpace_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::getSpace ) , bp::return_value_policy< bp::copy_const_reference >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::operator() typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::State * ( exported_class_t::*__call___function_type)( ) const; State_exposer.def( "__call__" , __call___function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::operator() ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::operator= typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::ScopedState< ompl::base::StateSpace > & ( exported_class_t::*assign_function_type)( ::ompl::base::ScopedState< ompl::base::StateSpace > const & ) ; State_exposer.def( "assign" , assign_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::operator= ) , ( bp::arg("other") ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::operator= typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::ScopedState< ompl::base::StateSpace > & ( exported_class_t::*assign_function_type)( ::ompl::base::State const * ) ; State_exposer.def( "assign" , assign_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::operator= ) , ( bp::arg("other") ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::operator= typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::ScopedState< ompl::base::StateSpace > & ( exported_class_t::*assign_function_type)( ::std::vector< double > const & ) ; State_exposer.def( "assign" , assign_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::operator= ) , ( bp::arg("reals") ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::operator= typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::ompl::base::ScopedState< ompl::base::StateSpace > & ( exported_class_t::*assign_function_type)( double const ) ; State_exposer.def( "assign" , assign_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::operator= ) , ( bp::arg("value") ) , bp::return_value_policy< bp::reference_existing_object >() ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::random typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef void ( exported_class_t::*random_function_type)( ) ; State_exposer.def( "random" , random_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::random ) ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::reals typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef ::std::vector< double > ( exported_class_t::*reals_function_type)( ) const; State_exposer.def( "reals" , reals_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::reals ) ); } { //::ompl::base::ScopedState< ompl::base::StateSpace >::satisfiesBounds typedef ompl::base::ScopedState< ompl::base::StateSpace > exported_class_t; typedef bool ( exported_class_t::*satisfiesBounds_function_type)( ) const; State_exposer.def( "satisfiesBounds" , satisfiesBounds_function_type( &::ompl::base::ScopedState< ompl::base::StateSpace >::satisfiesBounds ) ); } State_exposer.def("__getitem__", &__getitem); State_exposer.def("__setitem__", &__setitem); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::CompoundStateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::RealVectorStateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::SO2StateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::SO3StateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::SE2StateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::SE3StateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::DiscreteStateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::TimeStateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::DubinsStateSpace> const &>(( bp::arg("other") ))); State_exposer.def(bp::init<ompl::base::ScopedState<ompl::base::ReedsSheppStateSpace> const &>(( bp::arg("other") ))); State_exposer.def("__str__", &__str__); } }
// Make an undefined function declaration. The definition // must be assigned later. Function_decl* make_function_decl(Location loc, String const* n, Decl_seq const& p, Type const* r) { return new Function_decl(loc, n, get_function_type(p, r), p, nullptr); }
// Creates an undefined function with parameters ps and return // type r. Function_decl& Builder::make_function(Name& n, Decl_list const& ps, Type& r) { Type& t = get_function_type(ps, r); return make<Function_decl>(n, t, ps); }
hashkit_hash_algorithm_t hashkit_get_function(const hashkit_st *self) { return get_function_type(self->base_hash.function); }
hashkit_hash_algorithm_t hashkit_get_distribution_function(const hashkit_st *self) { return get_function_type(self->distribution_hash.function); }
void register_XMLAttributes_class(){ { //::osiris::XMLAttributes typedef ::boost::python::class_< ::osiris::XMLAttributes > XMLAttributes_exposer_t; XMLAttributes_exposer_t XMLAttributes_exposer = XMLAttributes_exposer_t( "XMLAttributes", ::boost::python::init< ::osiris::XMLNode & >(( ::boost::python::arg("node") )) ); ::boost::python::scope XMLAttributes_scope( XMLAttributes_exposer ); ::boost::python::implicitly_convertible< ::osiris::XMLNode &, ::osiris::XMLAttributes >(); { //::osiris::XMLAttributes::getNode typedef boost::python::object ( *getNode_function_type )( ::osiris::XMLAttributes & ); XMLAttributes_exposer.def( "getNode" , getNode_function_type( &getNode_4e57c0c8f9b0f179513dbc4a9f5d4c90 ) ); } { //::osiris::XMLAttributes::getNode typedef boost::python::object ( *getNode_function_type )( ::osiris::XMLAttributes const & ); XMLAttributes_exposer.def( "getNode" , getNode_function_type( &getNode_c7ca0ab9de3bad23f457972b89ccd4bc ) ); } { //::osiris::XMLAttributes::empty typedef boost::python::object ( *empty_function_type )( ::osiris::XMLAttributes const & ); XMLAttributes_exposer.def( "empty" , empty_function_type( &empty_b69603b713f1a8a59c2ffc4b6c71ff93 ) ); } { //::osiris::XMLAttributes::size typedef boost::python::object ( *size_function_type )( ::osiris::XMLAttributes const & ); XMLAttributes_exposer.def( "size" , size_function_type( &size_97d3881c48560de9a0f1e73dafa6a53e ) ); } { //::osiris::XMLAttributes::set typedef void ( *set_function_type )( ::osiris::XMLAttributes &,::osiris::String const &,::osiris::String const & ); XMLAttributes_exposer.def( "set" , set_function_type( &set_1e63dd0dc5475b37dd70f5a51470babd ) , ( ::boost::python::arg("inst"), ::boost::python::arg("name"), ::boost::python::arg("value") ) ); } { //::osiris::XMLAttributes::clear typedef void ( *clear_function_type )( ::osiris::XMLAttributes & ); XMLAttributes_exposer.def( "clear" , clear_function_type( &clear_bbd254cd8250d6049df9feeec423473d ) ); } { //::osiris::XMLAttributes::exists typedef boost::python::object ( *exists_function_type )( ::osiris::XMLAttributes const &,::osiris::String const & ); XMLAttributes_exposer.def( "exists" , exists_function_type( &exists_9b7ddaa903c86a33882aca33647d86d9 ) , ( ::boost::python::arg("inst"), ::boost::python::arg("name") ) ); } { //::osiris::XMLAttributes::find typedef boost::python::object ( *find_function_type )( ::osiris::XMLAttributes const &,::osiris::String const & ); XMLAttributes_exposer.def( "find" , find_function_type( &find_981dbb4e0c25761bece5c543ec955f9e ) , ( ::boost::python::arg("inst"), ::boost::python::arg("name") ) ); } { //::osiris::XMLAttributes::find typedef boost::python::object ( *find_function_type )( ::osiris::XMLAttributes const &,::size_t ); XMLAttributes_exposer.def( "find" , find_function_type( &find_f566384adab53722dbbf56f49e0e8597 ) , ( ::boost::python::arg("inst"), ::boost::python::arg("index") ) ); } { //::osiris::XMLAttributes::get typedef boost::python::object ( *get_function_type )( ::osiris::XMLAttributes const &,::osiris::String const & ); XMLAttributes_exposer.def( "get" , get_function_type( &get_8341dbbadae2779456a992562f1485db ) , ( ::boost::python::arg("inst"), ::boost::python::arg("name") ) ); } { //::osiris::XMLAttributes::remove typedef void ( *remove_function_type )( ::osiris::XMLAttributes &,::osiris::String const & ); XMLAttributes_exposer.def( "remove" , remove_function_type( &remove_13651ce1619d4c347a785c48f2131d08 ) , ( ::boost::python::arg("inst"), ::boost::python::arg("name") ) ); } ::boost::python::register_ptr_to_python< boost::shared_ptr< ::osiris::XMLAttributes > >(); ::boost::python::implicitly_convertible< boost::shared_ptr< ::osiris::XMLAttributes >, boost::shared_ptr< ::osiris::Object > >(); } }
// NOTE NOTE NOTE // ADDITIONS FOR LAMBDAS //Lambda_expr(Symbol * s, Decl_seq const& d, Type const * t, Stmt* const& b) Expr * Parser::on_lambda(Token tok, Decl_seq const& p, Type const* t, Stmt* b) { Type const* f = get_function_type(p, t); return init<Lambda_expr>(tok.location(), tok.symbol(), p, f, b); }
// Create a function with no body. This is a declaration // but not a definition. Decl* Parser::on_function(Specifier spec, Token tok, Decl_seq const& p, Type const* t) { Type const* f = get_function_type(p, t); return new Function_decl(spec, tok.symbol(), f, p, nullptr); }
Function_type& Builder::get_function_type(Type_list const& ts, Type& t, Qualifier_set q) { return get_function_type(banjo::function_type, ts, t, q); }
Function_type& Builder::get_function_type(Type_list&& ts, Type& t, Qualifier_set q) { return get_function_type(banjo::function_type, std::move(ts), t, q); }