Method: RCSimCinterface.rcsim_make_transmit
- Defined in:
- ext/hruby_sim/hruby_rcsim_build.c
.rcsim_make_transmit(left, right) ⇒ Object
Creating a transmit C object.
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 |
# File 'ext/hruby_sim/hruby_rcsim_build.c', line 507 VALUE rcsim_make_transmit(VALUE mod, VALUE left, VALUE right) { // printf("rcsim_make_transmit\n"); /* Allocates the transmit. */ Transmit transmit = (Transmit)malloc(sizeof(TransmitS)); // printf("transmit=%p\n",transmit); /* Set it up. */ transmit->kind = TRANSMIT; transmit->owner = NULL; value_to_rcsim(ReferenceS,left,transmit->left); value_to_rcsim(ExpressionS,right,transmit->right); /* Returns the C transmit embedded into a ruby VALUE. */ VALUE res; rcsim_to_value(TransmitS,transmit,res); return res; } |