You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Tim Wilson-Brown (JIRA)" <ji...@apache.org> on 2010/04/02 06:34:27 UTC

[jira] Updated: (THRIFT-750) C++ Compiler Virtual Function Option

     [ https://issues.apache.org/jira/browse/THRIFT-750?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tim Wilson-Brown updated THRIFT-750:
------------------------------------

    Attachment: t_cpp_generator.cc

Attached patched t_cpp_generator.cc from Thrift 0.2.0

> C++ Compiler Virtual Function Option
> ------------------------------------
>
>                 Key: THRIFT-750
>                 URL: https://issues.apache.org/jira/browse/THRIFT-750
>             Project: Thrift
>          Issue Type: New Feature
>          Components: Compiler (C++)
>    Affects Versions: 0.2, 0.3
>         Environment: Cygwin 1.7.1 on Windows XP SP3, Thrift 0.2.0 & r760184 & Trunk 
>            Reporter: Tim Wilson-Brown
>            Priority: Minor
>         Attachments: t_cpp_generator.cc
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> The C++ Compiler currelty emits most functions in the *Client class as non-virtual.
> This makes it impossible to subclass the generated class and override its functions.
> A workaround is to inherit from the interface class *If, override the functions, and use them to call a *Client class member pointer.
> But this can be cumbersome in some situations.
> I propose to add a virtual option to the C++ compiler that emits function declarations as virtual.
> I have attached a patched version of t_cpp_generator.cc from Thrift 0.2.0 - I can work out how to turn it into a patch file if needed.
> Is this worth merging into the trunk?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.