Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-1552

Thrift (cpp) include files shouldn't require adding "thrift" to the compilers include path.

    XMLWordPrintableJSON

Details

    Description

      When including thrift header files it is necessary to add thrift to the compilers include path. Headers are then included something like this...

      #include <thrift.h>
      #include <server/TNonblockingServer.h>
      #include <protocol/TBinaryProtocol.h>

      ... and so on.

      It is generally preferable to have include paths prefixed with the name of the library to which they belong. This not only prevents the possibility of include ambiguity it also acts as documentations and aids readability.

      This changes is to allow the header files to be included with "thrift" as the leading path leaf...

      #include <thrift/thrift.h>
      #include <thrift/server/TNonblockingServer.h>
      #include <thrift/protocol/TBinaryProtocol.h>

      We have already made this change to our version of thrift-0.5.0 and I am currently working on patching this change to trunk.

      Attachments

        Issue Links

          Activity

            People

              evilrix Ricky Cormier
              evilrix Ricky Cormier
              Votes:
              2 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 48h
                  48h
                  Remaining:
                  Remaining Estimate - 48h
                  48h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified