1 #ifndef PYROOT_TCALLCONTEXT_H
2 #define PYROOT_TCALLCONTEXT_H
24 LongDouble_t fLongDouble;
33 TCallContext( std::vector< TParameter >::size_type sz = 0 ) : fArgs( sz ), fFlags( 0 ) {}
49 static ECallFlags sMemoryPolicy;
50 static Bool_t SetMemoryPolicy( ECallFlags e );
53 static ECallFlags sSignalPolicy;
54 static Bool_t SetSignalPolicy( ECallFlags e );
57 std::vector< TParameter > fArgs;
61 inline Bool_t IsSorted( UInt_t flags ) {
62 return flags & TCallContext::kIsSorted;
65 inline Bool_t IsCreator( UInt_t flags ) {
66 return flags & TCallContext::kIsCreator;
69 inline Bool_t IsConstructor( UInt_t flags ) {
70 return flags & TCallContext::kIsConstructor;
73 inline Bool_t ManagesSmartPtr( TCallContext* ctxt ) {
74 return ctxt->fFlags & TCallContext::kManageSmartPtr;
77 inline Bool_t ReleasesGIL( UInt_t flags ) {
78 return flags & TCallContext::kReleaseGIL;
81 inline Bool_t ReleasesGIL( TCallContext* ctxt ) {
82 return ctxt ? (ctxt->fFlags & TCallContext::kReleaseGIL) : kFALSE;
85 inline Bool_t UseStrictOwnership( TCallContext* ctxt ) {
86 if ( ctxt && (ctxt->fFlags & TCallContext::kUseStrict) )
88 if ( ctxt && (ctxt->fFlags & TCallContext::kUseHeuristics) )
91 return TCallContext::sMemoryPolicy == TCallContext::kUseStrict;
96 #endif // !PYROOT_TCALLCONTEXT_H