MCPcopy Create free account
hub / github.com/boostorg/build / argument_list_bind_variables

Function argument_list_bind_variables

src/engine/function.cpp:3686–3717  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3684
3685
3686struct arg_list * argument_list_bind_variables( struct arg_list * formal,
3687 int32_t formal_count, module_t * module, int32_t * counter )
3688{
3689 if ( formal )
3690 {
3691 struct arg_list * result = (struct arg_list *)BJAM_MALLOC( sizeof(
3692 struct arg_list ) * formal_count );
3693 int32_t i;
3694
3695 for ( i = 0; i < formal_count; ++i )
3696 {
3697 int32_t j;
3698 struct argument * args = (struct argument *)BJAM_MALLOC( sizeof(
3699 struct argument ) * formal[ i ].size );
3700 for ( j = 0; j < formal[ i ].size; ++j )
3701 {
3702 args[ j ] = formal[ i ].args[ j ];
3703 if ( args[ j ].type_name )
3704 args[ j ].type_name = object_copy( args[ j ].type_name );
3705 args[ j ].arg_name = object_copy( args[ j ].arg_name );
3706 if ( args[ j ].flags != ARG_VARIADIC )
3707 args[ j ].index = module_add_fixed_var( module,
3708 args[ j ].arg_name, counter );
3709 }
3710 result[ i ].args = args;
3711 result[ i ].size = formal[ i ].size;
3712 }
3713
3714 return result;
3715 }
3716 return 0;
3717}
3718
3719
3720void argument_list_free( struct arg_list * args, int32_t args_count )

Callers 1

function_bind_variablesFunction · 0.85

Calls 2

object_copyFunction · 0.85
module_add_fixed_varFunction · 0.85

Tested by

no test coverage detected