35 #include "cling/Interpreter/Value.h" 37 #include <llvm/ADT/SmallVector.h> 69 mutable llvm::SmallVector<cling::Value, 8>
fArgVals;
75 void* compile_wrapper(
const std::string& wrapper_name,
76 const std::string& wrapper,
77 bool withAccessControl =
true);
79 void collect_type_info(clang::QualType& QT, std::ostringstream& typedefbuf,
80 std::ostringstream& callbuf, std::string& type_name,
81 bool& isReference,
bool& isPointer,
int indent_level,
84 void make_narg_call(
const unsigned N, std::ostringstream& typedefbuf,
85 std::ostringstream& callbuf,
86 const std::string& class_name,
int indent_level);
88 void make_narg_ctor(
const unsigned N, std::ostringstream& typedefbuf,
89 std::ostringstream& callbuf,
90 const std::string& class_name,
int indent_level);
92 void make_narg_call_with_return(
const unsigned N,
93 const std::string& class_name,
94 std::ostringstream& buf,
int indent_level);
96 void make_narg_ctor_with_return(
const unsigned N,
97 const std::string& class_name,
98 std::ostringstream& buf,
int indent_level);
109 template <
typename T>
110 void execWithLL(
void* address, clang::QualType QT,
113 template <
typename T>
114 void execWithULL(
void* address, clang::QualType QT,
116 void exec(
void* address,
void* ret)
const;
117 void exec_with_valref_return(
void* address,
119 void EvaluateArgList(
const std::string& ArgList);
122 template <
typename T>
123 T ExecT(
void* address);
133 : fInterp(interp), fNormCtxt(normCtxt), fWrapper(0), fIgnoreExtraArgs(false), fReturnIsRecordType(false)
139 : fInterp(minfo.GetInterpreter()), fNormCtxt(normCtxt), fWrapper(0), fIgnoreExtraArgs(false),
140 fReturnIsRecordType(false)
147 : fInterp(rhs.fInterp), fNormCtxt(rhs.fNormCtxt), fWrapper(rhs.fWrapper), fArgVals(rhs.fArgVals),
148 fIgnoreExtraArgs(rhs.fIgnoreExtraArgs), fReturnIsRecordType(rhs.fReturnIsRecordType)
155 void* ExecDefaultConstructor(
const TClingClassInfo* info,
void* address = 0,
156 unsigned long nary = 0UL);
158 unsigned long nary = 0UL,
bool withFree =
true);
159 void ExecWithReturn(
void* address,
void* ret = 0);
160 void ExecWithArgsAndReturn(
void* address,
161 const void* args[] = 0,
165 long ExecInt(
void* address);
166 long long ExecInt64(
void* address);
167 double ExecDouble(
void* address);
171 void Init(
const clang::FunctionDecl *);
174 void* InterfaceMethod();
175 bool IsValid()
const;
179 void SetArg(
long arg);
180 void SetArg(
unsigned long arg);
181 void SetArg(
float arg);
182 void SetArg(
double arg);
183 void SetArg(
long long arg);
184 void SetArg(
unsigned long long arg);
185 void SetArgArray(
long* argArr,
int narg);
186 void SetArgs(
const char* args);
188 const char* arglist,
long* poffset);
190 const char* arglist,
bool objectIsConst,
long* poffset);
193 const char*
proto,
long* poffset,
196 const char* proto,
bool objectIsConst,
long* poffset,
199 const llvm::SmallVectorImpl<clang::QualType>& proto,
203 const llvm::SmallVectorImpl<clang::QualType>& proto,
204 bool objectIsConst,
long* poffset,
208 #endif // ROOT_CallFunc
Emulation of the CINT MethodInfo class.
cling::Interpreter * fInterp
Cling interpreter, we do not own.
const clang::FunctionDecl * GetDecl() const
Emulation of the CINT CallFunc class.
void Init(TClassEdit::TInterpreterLookupHelper *helper)
void(* tcling_callfunc_ctor_Wrapper_t)(void **, void *, unsigned long)
TClingMethodInfo * fMethod
Current method, we own.
void(* tcling_callfunc_dtor_Wrapper_t)(void *, unsigned long, int)
const ROOT::TMetaUtils::TNormalizedCtxt & fNormCtxt
ROOT normalized context for that interpreter.
llvm::SmallVector< cling::Value, 8 > fArgVals
Stored function arguments, we own.
const clang::FunctionDecl * GetMethodDecl() const
bool fIgnoreExtraArgs
If true, do not limit number of function arguments to declared number.
Print a TSeq at the prompt:
Emulation of the CINT ClassInfo class.
TClingCallFunc(cling::Interpreter *interp, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt)
tcling_callfunc_Wrapper_t fWrapper
Pointer to compiled wrapper, we do not own.
void(* tcling_callfunc_Wrapper_t)(void *, int, void **, void *)
typedef void((*Func_t)())
TClingCallFunc(TClingMethodInfo &minfo, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt)
void IgnoreExtraArgs(bool ignore)
TClingCallFunc(const TClingCallFunc &rhs)