Saturday, October 4, 2014, 10:57:27 AM, you wrote:

> Make one of your public include files autoconf generated? Like we do for the 
> C APIs definitions file.

Close, but I think what would be better is to combine this with Brian's 
original thought.

So in Brian's shared pointer header, he has basically his original stuff -

#if ATS_USE_TR1
#  include <tr1/memory>
#else
#  include <memory>
#endif

namespace atscppapi {
#if ATS_USE_TR1
  using std::shared_ptr;
#else
  using std::tr1::shared_ptr;
#endif


what we do is use a variant of Leif's suggestion and make this a generated 
file. The original has something lke

# if ! defined(ATS_USE_TR1)
#   define ATS_USE_TR1 @TS_USE_TR1@
# endif

This way we get the configure time value as the default but if the plugin 
writer really wants control he can -D ATS_USE_TR1 to force a a different 
result. This could go in a common include or directly in the shared_ptr header. 
It depends on whether Brian thinks we will have more situations like this.

Reply via email to