GitHub user axos88 opened a pull request:

    https://github.com/apache/thrift/pull/33

    T monkeypatch thrift module

    Added fastcall struct that may be used to call by supplying a C function 
pointer or by rb_funcall if the C fptr is unavailable. 
    
    use by initailizing the fastcall by either fastcall_init_ruby (use 
rb_funcall), or fastcall_init_c (use a C fptr), and the call using 
fastcall_call(fastcall_struct, object, parameters)
    
    Drawback is that one parameter must be supplied, even if the needed 
parameters is 0, supply Qnil in this case.
    
    
    Added a new function to the protocol layer API, named 
get_protocol_method_table, which - if implemented - will return a C 
protocol_method_table structure containing the fastcall objectc to call its 
API. This is used to prevent having to switch ro ruby and back to C when two 
communicating layers are both implemented in C.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/whitepages/thrift t_monkeypatch_thrift_module

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/thrift/pull/33.patch

----

----

Reply via email to