#include "capi.h"
#include "cpp_cppyy.h"
#include "callcontext.h"
#include "TBaseClass.h"
#include "TClass.h"
#include "TClassRef.h"
#include "TClassTable.h"
#include "TClassEdit.h"
#include "TCollection.h"
#include "TDataMember.h"
#include "TDataType.h"
#include "TEnum.h"
#include "TEnumConstant.h"
#include "TEnv.h"
#include "TError.h"
#include "TException.h"
#include "TFunction.h"
#include "TFunctionTemplate.h"
#include "TGlobal.h"
#include "THashList.h"
#include "TInterpreter.h"
#include "TList.h"
#include "TListOfDataMembers.h"
#include "TListOfEnums.h"
#include "TMethod.h"
#include "TMethodArg.h"
#include "TROOT.h"
#include "TSystem.h"
#include <assert.h>
#include <algorithm>
#include <climits>
#include <stdexcept>
#include <map>
#include <new>
#include <set>
#include <sstream>
#include <signal.h>
#include <stdlib.h>
#include <string.h>
#include <typeinfo>
#include <iostream>
Macros | |
#define | CPPYY_HANDLE_EXCEPTION |
#define | CPPYY_IMP_CALL(typecode, rtype) |
#define | DIRECT_CALL ((size_t)1 << (8 * sizeof(size_t) - 1)) |
#define | FILL_COLL(type, filter) |
Typedefs | |
typedef std::vector< TClassRef > | ClassRefs_t |
typedef std::vector< TGlobal * > | GlobalVars_t |
typedef std::map< std::string, ClassRefs_t::size_type > | Name2ClassRefIndex_t |
typedef CPyCppyy::Parameter | Parameter |
Variables | |
static std::set< std::string > | g_builtins |
static GlobalVars_t | g_globalvars |
static Name2ClassRefIndex_t | g_name2classrefidx |
static bool | gEnableFastPath = true |
static std::set< std::string > | gInitialNames |
static const ClassRefs_t::size_type | GLOBAL_HANDLE = 1 |
static std::map< TDictionary::DeclId_t, CallWrapper * > | gMethodTemplates |
static std::set< std::string > | gRootSOs |
static std::set< std::string > | gSmartPtrTypes |
static std::set< std::string > | gSTLNames |
static std::vector< CallWrapper * > | gWrapperHolder |
static std::map< std::string, std::string > | resolved_enum_types |
static std::map< Cppyy::TCppType_t, bool > | sHasOperatorDelete |
const int | SMALL_ARGS_N = 8 |
static const ClassRefs_t::size_type | STD_HANDLE = GLOBAL_HANDLE + 1 |
#define CPPYY_HANDLE_EXCEPTION |
Definition at line 2364 of file clingwrapper.cxx.
#define CPPYY_IMP_CALL | ( | typecode, | |
rtype | |||
) |
Definition at line 845 of file clingwrapper.cxx.
#define DIRECT_CALL ((size_t)1 << (8 * sizeof(size_t) - 1)) |
Definition at line 57 of file clingwrapper.cxx.
#define FILL_COLL | ( | type, | |
filter | |||
) |
Definition at line 1071 of file clingwrapper.cxx.
typedef std::vector<TClassRef> ClassRefs_t |
Definition at line 63 of file clingwrapper.cxx.
typedef std::vector<TGlobal*> GlobalVars_t |
Definition at line 117 of file clingwrapper.cxx.
typedef std::map<std::string, ClassRefs_t::size_type> Name2ClassRefIndex_t |
Definition at line 68 of file clingwrapper.cxx.
typedef CPyCppyy::Parameter Parameter |
Definition at line 49 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 58 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 837 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 1082 of file clingwrapper.cxx.
Definition at line 757 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 357 of file clingwrapper.cxx.
cppyy_type_t cppyy_actual_class | ( | cppyy_type_t | klass, |
cppyy_object_t | obj | ||
) |
Definition at line 2328 of file clingwrapper.cxx.
void cppyy_add_smartptr_type | ( | const char * | type_name | ) |
Definition at line 2599 of file clingwrapper.cxx.
cppyy_object_t cppyy_allocate | ( | cppyy_type_t | type | ) |
Definition at line 2342 of file clingwrapper.cxx.
void * cppyy_allocate_function_args | ( | int | nargs | ) |
Definition at line 2491 of file clingwrapper.cxx.
char * cppyy_base_name | ( | cppyy_type_t | type, |
int | base_index | ||
) |
Definition at line 2583 of file clingwrapper.cxx.
ptrdiff_t cppyy_base_offset | ( | cppyy_type_t | derived, |
cppyy_type_t | base, | ||
cppyy_object_t | address, | ||
int | direction | ||
) |
Definition at line 2605 of file clingwrapper.cxx.
unsigned char cppyy_call_b | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2383 of file clingwrapper.cxx.
char cppyy_call_c | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2390 of file clingwrapper.cxx.
double cppyy_call_d | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2432 of file clingwrapper.cxx.
float cppyy_call_f | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2425 of file clingwrapper.cxx.
short cppyy_call_h | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2397 of file clingwrapper.cxx.
int cppyy_call_i | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2404 of file clingwrapper.cxx.
long cppyy_call_l | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2411 of file clingwrapper.cxx.
long double cppyy_call_ld | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2439 of file clingwrapper.cxx.
long long cppyy_call_ll | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2418 of file clingwrapper.cxx.
double cppyy_call_nld | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2446 of file clingwrapper.cxx.
cppyy_object_t cppyy_call_o | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args, | ||
cppyy_type_t | result_type | ||
) |
Definition at line 2477 of file clingwrapper.cxx.
void * cppyy_call_r | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2450 of file clingwrapper.cxx.
char * cppyy_call_s | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args, | ||
size_t * | lsz | ||
) |
Definition at line 2457 of file clingwrapper.cxx.
void cppyy_call_v | ( | cppyy_method_t | method, |
cppyy_object_t | self, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2377 of file clingwrapper.cxx.
cppyy_object_t cppyy_charp2stdstring | ( | const char * | str, |
size_t | sz | ||
) |
Definition at line 2818 of file clingwrapper.cxx.
int cppyy_compile | ( | const char * | code | ) |
Definition at line 2310 of file clingwrapper.cxx.
cppyy_object_t cppyy_construct | ( | cppyy_type_t | type | ) |
Definition at line 2350 of file clingwrapper.cxx.
cppyy_object_t cppyy_constructor | ( | cppyy_method_t | method, |
cppyy_type_t | klass, | ||
int | nargs, | ||
void * | args | ||
) |
Definition at line 2465 of file clingwrapper.cxx.
int cppyy_datamember_index | ( | cppyy_scope_t | scope, |
const char * | name | ||
) |
Definition at line 2753 of file clingwrapper.cxx.
char * cppyy_datamember_name | ( | cppyy_scope_t | scope, |
int | datamember_index | ||
) |
Definition at line 2741 of file clingwrapper.cxx.
intptr_t cppyy_datamember_offset | ( | cppyy_scope_t | scope, |
int | datamember_index | ||
) |
Definition at line 2749 of file clingwrapper.cxx.
char * cppyy_datamember_type | ( | cppyy_scope_t | scope, |
int | datamember_index | ||
) |
Definition at line 2745 of file clingwrapper.cxx.
void cppyy_deallocate | ( | cppyy_type_t | type, |
cppyy_object_t | self | ||
) |
Definition at line 2346 of file clingwrapper.cxx.
void cppyy_deallocate_function_args | ( | void * | args | ) |
Definition at line 2496 of file clingwrapper.cxx.
void cppyy_destruct | ( | cppyy_type_t | type, |
cppyy_object_t | self | ||
) |
Definition at line 2354 of file clingwrapper.cxx.
void cppyy_destructor | ( | cppyy_type_t | klass, |
cppyy_object_t | self | ||
) |
Definition at line 2473 of file clingwrapper.cxx.
void cppyy_double2longdouble | ( | double | d, |
void * | p | ||
) |
Definition at line 2835 of file clingwrapper.cxx.
int cppyy_exists_method_template | ( | cppyy_scope_t | scope, |
const char * | name | ||
) |
Definition at line 2697 of file clingwrapper.cxx.
char * cppyy_final_name | ( | cppyy_type_t | type | ) |
Definition at line 2559 of file clingwrapper.cxx.
void cppyy_free | ( | void * | ptr | ) |
Definition at line 2814 of file clingwrapper.cxx.
cppyy_funcaddr_t cppyy_function_address | ( | cppyy_method_t | method | ) |
Definition at line 2485 of file clingwrapper.cxx.
size_t cppyy_function_arg_sizeof | ( | ) |
Definition at line 2500 of file clingwrapper.cxx.
size_t cppyy_function_arg_typeoffset | ( | ) |
Definition at line 2504 of file clingwrapper.cxx.
const char ** cppyy_get_all_cpp_names | ( | cppyy_scope_t | scope, |
size_t * | count | ||
) |
Definition at line 2530 of file clingwrapper.cxx.
int cppyy_get_dimension_size | ( | cppyy_scope_t | scope, |
cppyy_index_t | idata, | ||
int | dimension | ||
) |
Definition at line 2780 of file clingwrapper.cxx.
cppyy_index_t cppyy_get_global_operator | ( | cppyy_scope_t | scope, |
cppyy_scope_t | lc, | ||
cppyy_scope_t | rc, | ||
const char * | op | ||
) |
Definition at line 2709 of file clingwrapper.cxx.
cppyy_method_t cppyy_get_method | ( | cppyy_scope_t | scope, |
cppyy_index_t | idx | ||
) |
Definition at line 2628 of file clingwrapper.cxx.
cppyy_method_t cppyy_get_method_template | ( | cppyy_scope_t | scope, |
const char * | name, | ||
const char * | proto | ||
) |
Definition at line 2705 of file clingwrapper.cxx.
int cppyy_get_num_templated_methods | ( | cppyy_scope_t | scope | ) |
Definition at line 2685 of file clingwrapper.cxx.
cppyy_scope_t cppyy_get_scope | ( | const char * | scope_name | ) |
Definition at line 2324 of file clingwrapper.cxx.
char * cppyy_get_templated_method_name | ( | cppyy_scope_t | scope, |
cppyy_index_t | imeth | ||
) |
Definition at line 2689 of file clingwrapper.cxx.
cppyy_scope_t * cppyy_get_using_namespaces | ( | cppyy_scope_t | scope | ) |
Definition at line 2545 of file clingwrapper.cxx.
int cppyy_has_complex_hierarchy | ( | cppyy_type_t | type | ) |
Definition at line 2571 of file clingwrapper.cxx.
int cppyy_has_virtual_destructor | ( | cppyy_type_t | type | ) |
Definition at line 2567 of file clingwrapper.cxx.
int cppyy_is_abstract | ( | cppyy_type_t | type | ) |
Definition at line 2518 of file clingwrapper.cxx.
int cppyy_is_aggregate | ( | cppyy_type_t | type | ) |
Definition at line 2526 of file clingwrapper.cxx.
int cppyy_is_const_data | ( | cppyy_scope_t | scope, |
cppyy_index_t | idata | ||
) |
Definition at line 2772 of file clingwrapper.cxx.
int cppyy_is_const_method | ( | cppyy_method_t | method | ) |
Definition at line 2681 of file clingwrapper.cxx.
int cppyy_is_constructor | ( | cppyy_method_t | method | ) |
Definition at line 2723 of file clingwrapper.cxx.
int cppyy_is_destructor | ( | cppyy_method_t | method | ) |
Definition at line 2727 of file clingwrapper.cxx.
int cppyy_is_enum | ( | const char * | type_name | ) |
Definition at line 2522 of file clingwrapper.cxx.
int cppyy_is_enum_data | ( | cppyy_scope_t | scope, |
cppyy_index_t | idata | ||
) |
Definition at line 2776 of file clingwrapper.cxx.
int cppyy_is_namespace | ( | cppyy_scope_t | scope | ) |
Definition at line 2510 of file clingwrapper.cxx.
int cppyy_is_protecteddata | ( | cppyy_type_t | type, |
cppyy_index_t | datamember_index | ||
) |
Definition at line 2764 of file clingwrapper.cxx.
int cppyy_is_protectedmethod | ( | cppyy_method_t | method | ) |
Definition at line 2719 of file clingwrapper.cxx.
int cppyy_is_publicdata | ( | cppyy_type_t | type, |
cppyy_index_t | datamember_index | ||
) |
Definition at line 2760 of file clingwrapper.cxx.
int cppyy_is_publicmethod | ( | cppyy_method_t | method | ) |
Definition at line 2715 of file clingwrapper.cxx.
int cppyy_is_smartptr | ( | cppyy_type_t | type | ) |
Definition at line 2591 of file clingwrapper.cxx.
int cppyy_is_staticdata | ( | cppyy_type_t | type, |
cppyy_index_t | datamember_index | ||
) |
Definition at line 2768 of file clingwrapper.cxx.
int cppyy_is_staticmethod | ( | cppyy_method_t | method | ) |
Definition at line 2731 of file clingwrapper.cxx.
int cppyy_is_subtype | ( | cppyy_type_t | derived, |
cppyy_type_t | base | ||
) |
Definition at line 2587 of file clingwrapper.cxx.
int cppyy_is_template | ( | const char * | template_name | ) |
Definition at line 2514 of file clingwrapper.cxx.
int cppyy_is_templated_constructor | ( | cppyy_scope_t | scope, |
cppyy_index_t | imeth | ||
) |
Definition at line 2693 of file clingwrapper.cxx.
void * cppyy_load_dictionary | ( | const char * | lib_name | ) |
Definition at line 2787 of file clingwrapper.cxx.
double cppyy_longdouble2double | ( | void * | p | ) |
Definition at line 2831 of file clingwrapper.cxx.
char * cppyy_method_arg_default | ( | cppyy_method_t | method, |
int | arg_index | ||
) |
Definition at line 2664 of file clingwrapper.cxx.
char * cppyy_method_arg_name | ( | cppyy_method_t | method, |
int | arg_index | ||
) |
Definition at line 2656 of file clingwrapper.cxx.
char * cppyy_method_arg_type | ( | cppyy_method_t | method, |
int | arg_index | ||
) |
Definition at line 2660 of file clingwrapper.cxx.
char * cppyy_method_full_name | ( | cppyy_method_t | method | ) |
Definition at line 2636 of file clingwrapper.cxx.
cppyy_index_t * cppyy_method_indices_from_name | ( | cppyy_scope_t | scope, |
const char * | name | ||
) |
Definition at line 2615 of file clingwrapper.cxx.
int cppyy_method_is_template | ( | cppyy_scope_t | scope, |
cppyy_index_t | idx | ||
) |
Definition at line 2701 of file clingwrapper.cxx.
char * cppyy_method_mangled_name | ( | cppyy_method_t | method | ) |
Definition at line 2640 of file clingwrapper.cxx.
char * cppyy_method_name | ( | cppyy_method_t | method | ) |
Definition at line 2632 of file clingwrapper.cxx.
int cppyy_method_num_args | ( | cppyy_method_t | method | ) |
Definition at line 2648 of file clingwrapper.cxx.
char * cppyy_method_prototype | ( | cppyy_scope_t | scope, |
cppyy_method_t | method, | ||
int | show_formalargs | ||
) |
Definition at line 2676 of file clingwrapper.cxx.
int cppyy_method_req_args | ( | cppyy_method_t | method | ) |
Definition at line 2652 of file clingwrapper.cxx.
char * cppyy_method_result_type | ( | cppyy_method_t | method | ) |
Definition at line 2644 of file clingwrapper.cxx.
char * cppyy_method_signature | ( | cppyy_method_t | method, |
int | show_formalargs | ||
) |
Definition at line 2668 of file clingwrapper.cxx.
char * cppyy_method_signature_max | ( | cppyy_method_t | method, |
int | show_formalargs, | ||
int | maxargs | ||
) |
Definition at line 2672 of file clingwrapper.cxx.
int cppyy_num_bases | ( | cppyy_type_t | type | ) |
Definition at line 2575 of file clingwrapper.cxx.
int cppyy_num_bases_longest_branch | ( | cppyy_type_t | type | ) |
Definition at line 2579 of file clingwrapper.cxx.
int cppyy_num_datamembers | ( | cppyy_scope_t | scope | ) |
Definition at line 2737 of file clingwrapper.cxx.
int cppyy_num_methods | ( | cppyy_scope_t | scope | ) |
Definition at line 2611 of file clingwrapper.cxx.
char * cppyy_resolve_enum | ( | const char * | enum_type | ) |
Definition at line 2320 of file clingwrapper.cxx.
char * cppyy_resolve_name | ( | const char * | cppitem_name | ) |
Definition at line 2316 of file clingwrapper.cxx.
char * cppyy_scoped_final_name | ( | cppyy_type_t | type | ) |
Definition at line 2563 of file clingwrapper.cxx.
size_t cppyy_size_of_klass | ( | cppyy_type_t | klass | ) |
Definition at line 2332 of file clingwrapper.cxx.
size_t cppyy_size_of_type | ( | const char * | type_name | ) |
Definition at line 2336 of file clingwrapper.cxx.
int cppyy_smartptr_info | ( | const char * | name, |
cppyy_type_t * | raw, | ||
cppyy_method_t * | deref | ||
) |
Definition at line 2595 of file clingwrapper.cxx.
const char * cppyy_stdstring2charp | ( | cppyy_object_t | ptr, |
size_t * | lsz | ||
) |
Definition at line 2822 of file clingwrapper.cxx.
cppyy_object_t cppyy_stdstring2stdstring | ( | cppyy_object_t | ptr | ) |
Definition at line 2827 of file clingwrapper.cxx.
long long cppyy_strtoll | ( | const char * | str | ) |
Definition at line 2803 of file clingwrapper.cxx.
unsigned long long cppyy_strtoull | ( | const char * | str | ) |
Definition at line 2808 of file clingwrapper.cxx.
int cppyy_vectorbool_getitem | ( | cppyy_object_t | ptr, |
int | idx | ||
) |
Definition at line 2839 of file clingwrapper.cxx.
void cppyy_vectorbool_setitem | ( | cppyy_object_t | ptr, |
int | idx, | ||
int | value | ||
) |
Definition at line 2843 of file clingwrapper.cxx.
|
static |
|
static |
Definition at line 723 of file clingwrapper.cxx.
|
static |
Definition at line 2021 of file clingwrapper.cxx.
Cppyy::TCppIndex_t GetLongestInheritancePath | ( | TClass * | klass | ) |
Retrieve number of base classes in the longest branch of the inheritance tree of the input class.
[in] | klass | The class to start the retrieval process from. |
This is a helper function for Cppyy::GetNumBasesLongestBranch. Given an inheritance tree, the function assigns weight 1 to each class that has at least one base. Starting from the input class, the function is called recursively on all the bases. For each base the return value is one (the weight of the base itself) plus the maximum value retrieved for their bases in turn. For example, given the following inheritance tree:
calling this function on an instance of C
will return 3, the steps required to go from C to X.
Definition at line 1322 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 377 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 347 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 337 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 365 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 110 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 103 of file clingwrapper.cxx.
|
static |
Definition at line 1059 of file clingwrapper.cxx.
|
static |
Definition at line 1033 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 779 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 330 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 1913 of file clingwrapper.cxx.
|
inlinestatic |
Definition at line 786 of file clingwrapper.cxx.
|
static |
Definition at line 128 of file clingwrapper.cxx.
|
static |
Definition at line 118 of file clingwrapper.cxx.
|
static |
Definition at line 69 of file clingwrapper.cxx.
|
static |
Definition at line 145 of file clingwrapper.cxx.
|
static |
Definition at line 141 of file clingwrapper.cxx.
|
static |
Definition at line 65 of file clingwrapper.cxx.
|
static |
Definition at line 1828 of file clingwrapper.cxx.
|
static |
Definition at line 142 of file clingwrapper.cxx.
|
static |
Definition at line 136 of file clingwrapper.cxx.
|
static |
Definition at line 120 of file clingwrapper.cxx.
|
static |
Definition at line 102 of file clingwrapper.cxx.
|
static |
Definition at line 463 of file clingwrapper.cxx.
|
static |
Definition at line 701 of file clingwrapper.cxx.
const int SMALL_ARGS_N = 8 |
Definition at line 54 of file clingwrapper.cxx.
|
static |
Definition at line 66 of file clingwrapper.cxx.