#include "rootcling_impl.h"
#include "rootclingCommandLineOptionsHelp.h"
#include "RConfigure.h"
#include <ROOT/RConfig.hxx>
#include <ROOT/FoundationUtils.hxx>
#include "snprintf.h"
#include <iostream>
#include <iomanip>
#include <memory>
#include <vector>
#include <algorithm>
#include <cstdio>
#include <errno.h>
#include <string>
#include <list>
#include <sstream>
#include <map>
#include <fstream>
#include <sys/stat.h>
#include <unordered_map>
#include <unordered_set>
#include <numeric>
#include <limits.h>
#include <unistd.h>
#include "cling/Interpreter/Interpreter.h"
#include "cling/Interpreter/InterpreterCallbacks.h"
#include "cling/Interpreter/LookupHelper.h"
#include "cling/Interpreter/Value.h"
#include "clang/AST/CXXInheritance.h"
#include "clang/Basic/Diagnostic.h"
#include "clang/Frontend/CompilerInstance.h"
#include "clang/Frontend/FrontendActions.h"
#include "clang/Frontend/FrontendDiagnostic.h"
#include "clang/Lex/HeaderSearch.h"
#include "clang/Lex/Preprocessor.h"
#include "clang/Lex/ModuleMap.h"
#include "clang/Lex/Pragma.h"
#include "clang/Sema/Sema.h"
#include "clang/Serialization/ASTWriter.h"
#include "cling/Utils/AST.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/PrettyStackTrace.h"
#include "llvm/Support/Signals.h"
#include "RtypesCore.h"
#include "TModuleGenerator.h"
#include "TClassEdit.h"
#include "TClingUtils.h"
#include "RStl.h"
#include "XMLReader.h"
#include "LinkdefReader.h"
#include "DictSelectionReader.h"
#include "SelectionRules.h"
#include "Scanner.h"
#include "strlcpy.h"
#include "OptionParser.h"
#include "clang/Basic/LangOptions.def"
Classes | |
class | CheckModuleBuildClient |
Custom diag client for clang that verifies that each implicitly build module is a system module. More... | |
class | tempFileNamesCatalog |
Little helper class to bookkeep the files names which we want to make temporary. More... | |
class | TRootClingCallbacks |
Namespaces | |
namespace | genreflex |
Macros | |
#define | ENUM_LANGOPT(Name, Type, Bits, Default, Description) |
#define | LANGOPT(Name, Bits, Default, Description) ROOT::TMetaUtils::Info(nullptr, "%s = %d // %s\n", #Name, (int)LangOpts.Name, Description); |
#define | rootclingStringify(s) rootclingStringifyx(s) |
#define | rootclingStringifyx(s) #s |
Typedefs | |
using | HeadersDeclsMap_t = std::map< std::string, std::list< std::string > > |
Enumerations | |
enum | VerboseLevel { v = ROOT::TMetaUtils::kError , v0 = ROOT::TMetaUtils::kFatal , v1 = v , v2 = ROOT::TMetaUtils::kWarning , v3 = ROOT::TMetaUtils::kNote , v4 = ROOT::TMetaUtils::kInfo } |
Functions | |
void | AddNamespaceSTDdeclaration (std::ostream &dictStream) |
void | AddPlatformDefines (std::vector< std::string > &clingArgs) |
void | genreflex::AddToArgVector (std::vector< char * > &argvVector, const std::vector< std::string > &argsToBeAdded, const std::string &optName="") |
void | genreflex::AddToArgVectorSplit (std::vector< char * > &argvVector, const std::vector< std::string > &argsToBeAdded, const std::string &optName="") |
void | AdjustRootMapNames (std::string &rootmapFileName, std::string &rootmapLibName) |
void | AnnotateAllDeclsForPCH (cling::Interpreter &interp, RScanner &scan) |
We need annotations even in the PCH: // !, // || etc. | |
void | AnnotateDecl (clang::CXXRecordDecl &CXXRD, const RScanner::DeclsSelRulesMap_t &declSelRulesMap, cling::Interpreter &interpreter, bool isGenreflex) |
static void | AnnotateFieldDecl (clang::FieldDecl &decl, const std::list< VariableSelectionRule > &fieldSelRules) |
void | CallWriteStreamer (const ROOT::TMetaUtils::AnnotatedRecordDecl &cl, const cling::Interpreter &interp, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt, std::ostream &dictStream, bool isAutoStreamer) |
void | genreflex::changeExtension (std::string &filename, const std::string &newExtension) |
bool | CheckClassDef (const clang::RecordDecl &cl, const cling::Interpreter &interp) |
Return false if the class does not have ClassDef even-though it should. | |
int | CheckClassesForInterpreterOnlyDicts (cling::Interpreter &interp, RScanner &scan) |
void | CheckClassNameForRootMap (const std::string &classname, map< string, string > &autoloads) |
static void | CheckForMinusW (std::string arg, std::list< std::string > &diagnosticPragmas) |
Transform -W statements in diagnostic pragmas for cling reacting on "-Wno-" For example -Wno-deprecated-declarations --> #pragma clang diagnostic ignored "-Wdeprecated-declarations" | |
int | CheckForUnsupportedClasses (const RScanner::ClassColl_t &annotatedRcds) |
Check if the list of selected classes contains any class which is not supported. | |
unsigned int | genreflex::checkHeadersNames (std::vector< std::string > &headersNames) |
Loop on arguments: stop at the first which starts with -. | |
bool | CheckInputOperator (const char *what, const char *proto, const string &fullname, const clang::RecordDecl *cl, cling::Interpreter &interp) |
Check if the specified operator (what) has been properly declared if the user has requested a custom version. | |
bool | CheckInputOperator (const clang::RecordDecl *cl, cling::Interpreter &interp) |
Check if the operator>> has been properly declared if the user has requested a custom version. | |
static bool | CheckModuleValid (TModuleGenerator &modGen, const std::string &resourceDir, cling::Interpreter &interpreter, llvm::StringRef LinkdefPath, const std::string &moduleName) |
Check moduleName validity from modulemap. Check if this module is defined or not. | |
std::list< std::string > | CollapseIdenticalNamespaces (const std::list< std::string > &fwdDeclarationsList) |
If two identical namespaces are there, just declare one only Example: namespace A { namespace B { fwd1; }} namespace A { namespace B { fwd2; }} get a namespace A { namespace B { fwd1; fwd2; }} line. | |
const char * | CopyArg (const char *original) |
If the argument starts with MODULE/inc, strip it to make it the name we can use in #includes . | |
void | CreateDictHeader (std::ostream &dictStream, const std::string &main_dictname) |
int | CreateNewRootMapFile (const std::string &rootmapFileName, const std::string &rootmapLibName, const std::list< std::string > &classesDefsList, const std::list< std::string > &classesNames, const std::list< std::string > &nsNames, const std::list< std::string > &tdNames, const std::list< std::string > &enNames, const std::list< std::string > &varNames, const HeadersDeclsMap_t &headersClassesMap, const std::unordered_set< std::string > headersToIgnore) |
Generate a rootmap file in the new format, like { decls } namespace A { namespace B { template <typename T> class myTemplate; } } [libGpad.so libGraf.so libHist.so libMathCore.so] class TAttCanvas class TButton (header1.h header2.h . | |
std::ostream * | CreateStreamPtrForSplitDict (const std::string &dictpathname, tempFileNamesCatalog &tmpCatalog) |
Transform name of dictionary. | |
static void | EmitEnums (const std::vector< const clang::EnumDecl * > &enumvec) |
void | EmitStreamerInfo (const char *normName) |
static void | EmitTypedefs (const std::vector< const clang::TypedefNameDecl * > &tdvec) |
unsigned int | genreflex::extractArgs (int argc, char **argv, std::vector< std::string > &args) |
Extract the arguments from the command line. | |
template<class COLL > | |
int | ExtractAutoloadKeys (std::list< std::string > &names, const COLL &decls, const cling::Interpreter &interp) |
int | ExtractClassesListAndDeclLines (RScanner &scan, std::list< std::string > &classesList, std::list< std::string > &classesListForRootmap, std::list< std::string > &fwdDeclarationsList, const cling::Interpreter &interpreter) |
std::string | ExtractFileName (const std::string &path) |
Extract the filename from a fullpath. | |
void | ExtractFilePath (const std::string &path, std::string &dirname) |
Extract the path from a fullpath finding the last \ or / according to the content in gPathSeparator. | |
void | ExtractHeadersForDecls (const RScanner::ClassColl_t &annotatedRcds, const RScanner::TypedefColl_t tDefDecls, const RScanner::FunctionColl_t funcDecls, const RScanner::VariableColl_t varDecls, const RScanner::EnumColl_t enumDecls, HeadersDeclsMap_t &headersClassesMap, HeadersDeclsMap_t &headersDeclsMap, const cling::Interpreter &interp) |
int | extractMultipleOptions (std::vector< ROOT::option::Option > &options, int oIndex, std::vector< std::string > &values) |
Extract from options multiple values with the same option. | |
void | ExtractSelectedNamespaces (RScanner &scan, std::list< std::string > &nsList) |
Loop on selected classes and put them in a list. | |
int | FinalizeStreamerInfoWriting (cling::Interpreter &interp, bool writeEmptyRootPCM=false) |
Make up for skipping RegisterModule, now that dictionary parsing is done and these headers cannot be selected anymore. | |
static llvm::cl::SubCommand | gBareClingSubcommand ("bare-cling", "Call directly cling and exit.") |
static bool | GenerateAllDict (TModuleGenerator &modGen, clang::CompilerInstance *compilerInstance, const std::string ¤tDirectory) |
Generates a PCH from the given ModuleGenerator and CompilerInstance. | |
int | GenerateFullDict (std::ostream &dictStream, cling::Interpreter &interp, RScanner &scan, const ROOT::TMetaUtils::RConstructorTypes &ctorTypes, bool isSplit, bool isGenreflex, bool isSelXML, bool writeEmptyRootPCM) |
static std::string | GenerateFwdDeclString (const RScanner &scan, const cling::Interpreter &interp) |
Generate the fwd declarations of the selected entities. | |
void | GenerateLinkdef (llvm::cl::list< std::string > &InputFiles, std::string &code_for_parser) |
void | GenerateNecessaryIncludes (std::ostream &dictStream, const std::string &includeForSource, const std::string &extraIncludes) |
const std::string | GenerateStringFromHeadersForClasses (const HeadersDeclsMap_t &headersClassesMap, const std::string &detectedUmbrella, bool payLoadOnly=false) |
Generate a string for the dictionary from the headers-classes map. | |
int | GenReflexMain (int argc, char **argv) |
Translate the arguments of genreflex into rootcling ones and forward them to the RootCling function. | |
const char * | GetExePath () |
Returns the executable path name, used e.g. by SetRootSys(). | |
std::pair< std::string, std::string > | GetExternalNamespaceAndContainedEntities (const std::string line) |
Performance is not critical here. | |
size_t | GetFullArrayLength (const clang::ConstantArrayType *arrayType) |
std::string | GetFwdDeclnArgsToKeepString (const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt, cling::Interpreter &interp) |
static llvm::StringRef | GetModuleNameFromRdictName (llvm::StringRef rdictName) |
void | GetMostExternalEnclosingClassName (const clang::DeclContext &theContext, std::string &ctxtName, const cling::Interpreter &interpreter, bool treatParent=true) |
Extract the proper autoload key for nested classes The routine does not erase the name, just updates it. | |
void | GetMostExternalEnclosingClassNameFromDecl (const clang::Decl &theDecl, std::string &ctxtName, const cling::Interpreter &interpreter) |
string | GetNonConstMemberName (const clang::FieldDecl &m, const string &prefix="") |
Return the name of the data member so that it can be used by non-const operation (so it includes a const_cast if necessary). | |
clang::QualType | GetPointeeTypeIfPossible (const clang::QualType &qt) |
Get the pointee type if possible. | |
const std::string | gLibraryExtension (".so") |
static llvm::cl::list< std::string > | gOptBareClingSink (llvm::cl::OneOrMore, llvm::cl::Sink, llvm::cl::desc("Consumes options and sends them to cling."), llvm::cl::cat(gRootclingOptions), llvm::cl::sub(gBareClingSubcommand)) |
static llvm::cl::opt< bool > | gOptC ("c", llvm::cl::desc("Deprecated, legacy flag which is ignored."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptCheckSelectionSyntax ("selSyntaxOnly", llvm::cl::desc("Check the selection syntax only."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptCint ("cint", llvm::cl::desc("Deprecated, legacy flag which is ignored."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptCompDefaultIncludePaths ("compilerI", llvm::cl::Prefix, llvm::cl::ZeroOrMore, llvm::cl::desc("Specify a compiler default include path, to suppress unneeded `-isystem` arguments."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptCxxModule ("cxxmodule", llvm::cl::desc("Generate a C++ module."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< std::string > | gOptDictionaryFileName (llvm::cl::Positional, llvm::cl::desc("<output dictionary file>"), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptDictionaryHeaderFiles (llvm::cl::Positional, llvm::cl::ZeroOrMore, llvm::cl::desc("<list of dictionary header files> <LinkDef file | selection xml file>"), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptExcludePaths ("excludePath", llvm::cl::ZeroOrMore, llvm::cl::desc("Do not store the <path> in the dictionary."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptFailOnWarnings ("failOnWarnings", llvm::cl::desc("Fail if there are warnings."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptForce ("f", llvm::cl::desc("Overwrite <file>s."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptGccXml ("gccxml", llvm::cl::desc("Deprecated, legacy flag which is ignored."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptGeneratePCH ("generate-pch", llvm::cl::desc("Generates a pch file from a predefined set of headers. See makepch.py."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptIgnoreExistingDict ("r", llvm::cl::desc("Deprecated. Similar to -f but it ignores the dictionary generation. \ When -r is present rootcling becomes a tool to generate rootmaps (and capability files)."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptIncludePaths ("I", llvm::cl::Prefix, llvm::cl::ZeroOrMore, llvm::cl::desc("Specify an include path."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptInlineInput ("inlineInputHeader", llvm::cl::desc("Does not generate #include <header> but expands the header content."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptInterpreterOnly ("interpreteronly", llvm::cl::desc("Generate minimal dictionary for interactivity (without IO information)."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< std::string > | gOptISysRoot ("isysroot", llvm::cl::Prefix, llvm::cl::Hidden, llvm::cl::desc("Specify an isysroot."), llvm::cl::cat(gRootclingOptions), llvm::cl::init("-")) |
static llvm::cl::opt< std::string > | gOptLibListPrefix ("lib-list-prefix", llvm::cl::desc("An ACLiC feature which exports the list of dependent libraries."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptModuleByproducts ("mByproduct", llvm::cl::ZeroOrMore, llvm::cl::Hidden, llvm::cl::desc("The list of the expected implicit modules build as part of building the current module."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptModuleDependencies ("m", llvm::cl::desc("The list of dependent modules of the dictionary."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptModuleMapFiles ("moduleMapFile", llvm::cl::desc("Specify a C++ modulemap file."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptMultiDict ("multiDict", llvm::cl::desc("If this library has multiple separate LinkDef files."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptNoDictSelection ("noDictSelection", llvm::cl::Hidden, llvm::cl::desc("Do not run the selection rules. Useful when in -onepcm mode."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptNoGlobalUsingStd ("noGlobalUsingStd", llvm::cl::desc("Do not declare {using namespace std} in dictionary global scope."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptNoIncludePaths ("noIncludePaths", llvm::cl::desc("Do not store include paths but rely on the env variable ROOT_INCLUDE_PATH."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptP ("p", llvm::cl::desc("Deprecated, legacy flag which is ignored."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptPPDefines ("D", llvm::cl::Prefix, llvm::cl::ZeroOrMore, llvm::cl::desc("Specify defined macros."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptPPUndefines ("U", llvm::cl::Prefix, llvm::cl::ZeroOrMore, llvm::cl::desc("Specify undefined macros."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptReflex ("reflex", llvm::cl::desc("Behave internally like genreflex."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptRootBuild ("rootbuild", llvm::cl::desc("If we are building ROOT."), llvm::cl::Hidden, llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< std::string > | gOptRootMapFileName ("rmf", llvm::cl::desc("Generate a rootmap file with the specified name."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptRootmapLibNames ("rml", llvm::cl::ZeroOrMore, llvm::cl::desc("Generate rootmap file."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< std::string > | gOptSharedLibFileName ("s", llvm::cl::desc("The path to the library of the built dictionary."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptSink (llvm::cl::ZeroOrMore, llvm::cl::Sink, llvm::cl::desc("Consumes all unrecognized options."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptSplit ("split", llvm::cl::desc("Split the dictionary into two parts: one containing the IO (ClassDef)\ information and another the interactivity support."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptSysIncludePaths ("isystem", llvm::cl::ZeroOrMore, llvm::cl::desc("Specify a system include path."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptSystemModuleByproducts ("mSystemByproducts", llvm::cl::Hidden, llvm::cl::desc("Allow implicit build of system modules."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptUmbrellaInput ("umbrellaHeader", llvm::cl::desc("A single header including all headers instead of specifying them on the command line."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< VerboseLevel > | gOptVerboseLevel (llvm::cl::desc("Choose verbosity level:"), llvm::cl::values(clEnumVal(v, "Show errors."), clEnumVal(v0, "Show only fatal errors."), clEnumVal(v1, "Show errors (the same as -v)."), clEnumVal(v2, "Show warnings (default)."), clEnumVal(v3, "Show notes."), clEnumVal(v4, "Show information.")), llvm::cl::init(v2), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::list< std::string > | gOptWDiags ("W", llvm::cl::Prefix, llvm::cl::ZeroOrMore, llvm::cl::desc("Specify compiler diagnostics options."), llvm::cl::cat(gRootclingOptions)) |
static llvm::cl::opt< bool > | gOptWriteEmptyRootPCM ("writeEmptyRootPCM", llvm::cl::Hidden, llvm::cl::desc("Does not include the header files as it assumes they exist in the pch."), llvm::cl::cat(gRootclingOptions)) |
const std::string | gPathSeparator (ROOT::TMetaUtils::GetPathSeparator()) |
llvm::StringRef | GrabIndex (const cling::Interpreter &interp, const clang::FieldDecl &member, int printError) |
GrabIndex returns a static string (so use it or copy it immediately, do not call GrabIndex twice in the same expression) containing the size of the array data member. | |
static llvm::cl::OptionCategory | gRootclingOptions ("rootcling common options") |
bool | HasPath (const std::string &name) |
Check if file has a path. | |
void | genreflex::header2outputName (std::string &fileName) |
Replace the extension with "_rflx.cpp". | |
void | genreflex::headers2outputsNames (const std::vector< std::string > &headersNames, std::vector< std::string > &ofilesnames) |
Get a proper name for the output file. | |
static bool | IncludeHeaders (const std::vector< std::string > &headers, cling::Interpreter &interpreter) |
Includes all given headers in the interpreter. | |
bool | InheritsFromTObject (const clang::RecordDecl *cl, const cling::Interpreter &interp) |
bool | InheritsFromTSelector (const clang::RecordDecl *cl, const cling::Interpreter &interp) |
static bool | InjectModuleUtilHeader (const char *argv0, TModuleGenerator &modGen, cling::Interpreter &interp, bool umbrella) |
Write the extra header injected into the module: umbrella header if (umbrella) else content header. | |
int | genreflex::invokeManyRootCling (const std::string &verbosity, const std::string &selectionFileName, const std::string &targetLibName, bool multiDict, const std::vector< std::string > &pcmsNames, const std::vector< std::string > &includes, const std::vector< std::string > &preprocDefines, const std::vector< std::string > &preprocUndefines, const std::vector< std::string > &warnings, const std::string &rootmapFileName, const std::string &rootmapLibName, bool interpreteronly, bool doSplit, bool isCxxmodule, bool writeEmptyRootPCM, bool selSyntaxOnly, bool noIncludePaths, bool noGlobalUsingStd, const std::vector< std::string > &headersNames, bool failOnWarnings, bool printRootclingInvocation, const std::string &outputDirName_const="") |
Get the right ofilenames and invoke several times rootcling One invokation per header. | |
int | genreflex::invokeRootCling (const std::string &verbosity, const std::string &selectionFileName, const std::string &targetLibName, bool multiDict, const std::vector< std::string > &pcmsNames, const std::vector< std::string > &includes, const std::vector< std::string > &preprocDefines, const std::vector< std::string > &preprocUndefines, const std::vector< std::string > &warnings, const std::string &rootmapFileName, const std::string &rootmapLibName, bool interpreteronly, bool doSplit, bool isCxxmodule, bool writeEmptyRootPCM, bool selSyntaxOnly, bool noIncludePaths, bool noGlobalUsingStd, const std::vector< std::string > &headersNames, bool failOnWarnings, bool printRootclingInvocation, const std::string &ofilename) |
bool | IsCorrectClingArgument (const std::string &argument) |
Check if the argument is a sane cling argument. | |
bool | IsGoodForAutoParseMap (const clang::RecordDecl &rcd) |
Check if the class good for being an autoparse key. | |
bool | IsGoodLibraryName (const std::string &name) |
bool | IsImplementationName (const std::string &filename) |
bool | IsLinkdefFile (const clang::PresumedLoc &PLoc) |
bool | isPointerToPointer (const clang::FieldDecl &m) |
bool | IsSelectionFile (const char *filename) |
bool | IsSelectionXml (const char *filename) |
bool | IsSupportedClassName (const char *name) |
void | LoadLibraryMap (const std::string &fileListName, map< string, string > &autoloads) |
Fill the map of libraries to be loaded in presence of a class Transparently support the old and new rootmap file format. | |
static void | MaybeSuppressWin32CrashDialogs () |
static bool | ModuleContainsHeaders (TModuleGenerator &modGen, clang::HeaderSearch &headerSearch, clang::Module *module, std::vector< std::array< std::string, 2 > > &missingHeaders) |
Returns true iff a given module (and its submodules) contains all headers needed by the given ModuleGenerator. | |
bool | Namespace__HasMethod (const clang::NamespaceDecl *cl, const char *name, const cling::Interpreter &interp) |
bool | NeedsSelection (const char *name) |
bool | ParsePragmaLine (const std::string &line, const char *expectedTokens[], size_t *end=nullptr) |
Check whether the #pragma line contains expectedTokens (0-terminated array). | |
void | ParseRootMapFile (ifstream &file, map< string, string > &autoloads) |
Parse the rootmap and add entries to the autoload map. | |
void | ParseRootMapFileNewFormat (ifstream &file, map< string, string > &autoloads) |
Parse the rootmap and add entries to the autoload map, using the new format. | |
bool | ProcessAndAppendIfNotThere (const std::string &el, std::list< std::string > &el_list, std::unordered_set< std::string > &el_set) |
Separate multiline strings. | |
std::list< std::string > | RecordDecl2Headers (const clang::CXXRecordDecl &rcd, const cling::Interpreter &interp, std::set< const clang::CXXRecordDecl * > &visitedDecls) |
Extract the list of headers necessary for the Decl. | |
void | RecordDeclCallback (const clang::RecordDecl *recordDecl) |
void | RiseWarningIfPresent (std::vector< ROOT::option::Option > &options, int optionIndex, const char *descriptor) |
int | ROOT_rootcling_Driver (int argc, char **argv, const ROOT::Internal::RootCling::DriverConfig &config) |
int | RootClingMain (int argc, char **argv, bool isGenreflex=false) |
void | SetRootSys () |
Set the ROOTSYS env var based on the executable location. | |
int | STLContainerStreamer (const clang::FieldDecl &m, int rwmode, const cling::Interpreter &interp, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt, std::ostream &dictStream) |
Create Streamer code for an STL container. | |
int | STLStringStreamer (const clang::FieldDecl &m, int rwmode, std::ostream &dictStream) |
Create Streamer code for a standard string object. | |
void | StrcpyArg (string &dest, const char *original) |
Copy the command line argument, stripping MODULE/inc if necessary. | |
char * | genreflex::string2charptr (const std::string &str) |
The caller is responsible for deleting the string! | |
bool | Which (cling::Interpreter &interp, const char *fname, string &pname) |
Find file name in path specified via -I statements to Cling. | |
void | WriteArrayDimensions (const clang::QualType &type, std::ostream &dictStream) |
Write "[0]" for all but the 1st dimension. | |
static bool | WriteAST (llvm::StringRef fileName, clang::CompilerInstance *compilerInstance, llvm::StringRef iSysRoot, clang::Module *module=nullptr) |
Write the AST of the given CompilerInstance to the given File while respecting the given isysroot. | |
void | WriteAutoStreamer (const ROOT::TMetaUtils::AnnotatedRecordDecl &cl, const cling::Interpreter &interp, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt, std::ostream &dictStream) |
void | WriteClassFunctions (const clang::CXXRecordDecl *cl, std::ostream &dictStream, bool autoLoad=false) |
Write the code to set the class name and the initialization object. | |
void | WriteNamespaceInit (const clang::NamespaceDecl *cl, cling::Interpreter &interp, std::ostream &dictStream) |
Write the code to initialize the namespace name and the initialization object. | |
void | WriteStreamer (const ROOT::TMetaUtils::AnnotatedRecordDecl &cl, const cling::Interpreter &interp, const ROOT::TMetaUtils::TNormalizedCtxt &normCtxt, std::ostream &dictStream) |
Variables | |
map< string, string > | gAutoloads |
bool | gBuildingROOT = false |
const ROOT::Internal::RootCling::DriverConfig * | gDriverConfig = nullptr |
string | gLibsNeeded |
bool | genreflex::verbose = false |
#define ENUM_LANGOPT | ( | Name, | |
Type, | |||
Bits, | |||
Default, | |||
Description | |||
) |
#define LANGOPT | ( | Name, | |
Bits, | |||
Default, | |||
Description | |||
) | ROOT::TMetaUtils::Info(nullptr, "%s = %d // %s\n", #Name, (int)LangOpts.Name, Description); |
#define rootclingStringify | ( | s | ) | rootclingStringifyx(s) |
Definition at line 131 of file rootcling_impl.cxx.
#define rootclingStringifyx | ( | s | ) | #s |
Definition at line 132 of file rootcling_impl.cxx.
using HeadersDeclsMap_t = std::map<std::string, std::list<std::string> > |
Definition at line 135 of file rootcling_impl.cxx.
enum VerboseLevel |
Enumerator | |
---|---|
v | |
v0 | |
v1 | |
v2 | |
v3 | |
v4 |
Definition at line 3698 of file rootcling_impl.cxx.
void AddNamespaceSTDdeclaration | ( | std::ostream & | dictStream | ) |
Definition at line 2854 of file rootcling_impl.cxx.
void AddPlatformDefines | ( | std::vector< std::string > & | clingArgs | ) |
Definition at line 2067 of file rootcling_impl.cxx.
void AdjustRootMapNames | ( | std::string & | rootmapFileName, |
std::string & | rootmapLibName | ||
) |
Definition at line 2175 of file rootcling_impl.cxx.
void AnnotateAllDeclsForPCH | ( | cling::Interpreter & | interp, |
RScanner & | scan | ||
) |
We need annotations even in the PCH: // !, // || etc.
Definition at line 2583 of file rootcling_impl.cxx.
void AnnotateDecl | ( | clang::CXXRecordDecl & | CXXRD, |
const RScanner::DeclsSelRulesMap_t & | declSelRulesMap, | ||
cling::Interpreter & | interpreter, | ||
bool | isGenreflex | ||
) |
Definition at line 327 of file rootcling_impl.cxx.
|
static |
Definition at line 253 of file rootcling_impl.cxx.
void CallWriteStreamer | ( | const ROOT::TMetaUtils::AnnotatedRecordDecl & | cl, |
const cling::Interpreter & | interp, | ||
const ROOT::TMetaUtils::TNormalizedCtxt & | normCtxt, | ||
std::ostream & | dictStream, | ||
bool | isAutoStreamer | ||
) |
Definition at line 1832 of file rootcling_impl.cxx.
bool CheckClassDef | ( | const clang::RecordDecl & | cl, |
const cling::Interpreter & | interp | ||
) |
Return false if the class does not have ClassDef even-though it should.
Definition at line 801 of file rootcling_impl.cxx.
Definition at line 2598 of file rootcling_impl.cxx.
void CheckClassNameForRootMap | ( | const std::string & | classname, |
map< string, string > & | autoloads | ||
) |
Definition at line 595 of file rootcling_impl.cxx.
|
static |
Transform -W statements in diagnostic pragmas for cling reacting on "-Wno-" For example -Wno-deprecated-declarations --> #pragma clang diagnostic ignored "-Wdeprecated-declarations"
Definition at line 3032 of file rootcling_impl.cxx.
int CheckForUnsupportedClasses | ( | const RScanner::ClassColl_t & | annotatedRcds | ) |
Check if the list of selected classes contains any class which is not supported.
Return the number of unsupported classes in the selection.
Definition at line 3459 of file rootcling_impl.cxx.
bool CheckInputOperator | ( | const char * | what, |
const char * | proto, | ||
const string & | fullname, | ||
const clang::RecordDecl * | cl, | ||
cling::Interpreter & | interp | ||
) |
Check if the specified operator (what) has been properly declared if the user has requested a custom version.
Definition at line 728 of file rootcling_impl.cxx.
bool CheckInputOperator | ( | const clang::RecordDecl * | cl, |
cling::Interpreter & | interp | ||
) |
Check if the operator>> has been properly declared if the user has requested a custom version.
Definition at line 778 of file rootcling_impl.cxx.
|
static |
Check moduleName validity from modulemap. Check if this module is defined or not.
Definition at line 3946 of file rootcling_impl.cxx.
std::list< std::string > CollapseIdenticalNamespaces | ( | const std::list< std::string > & | fwdDeclarationsList | ) |
If two identical namespaces are there, just declare one only Example: namespace A { namespace B { fwd1; }} namespace A { namespace B { fwd2; }} get a namespace A { namespace B { fwd1; fwd2; }} line.
Definition at line 2380 of file rootcling_impl.cxx.
const char * CopyArg | ( | const char * | original | ) |
If the argument starts with MODULE/inc, strip it to make it the name we can use in #includes
.
Definition at line 1943 of file rootcling_impl.cxx.
void CreateDictHeader | ( | std::ostream & | dictStream, |
const std::string & | main_dictname | ||
) |
Definition at line 2812 of file rootcling_impl.cxx.
int CreateNewRootMapFile | ( | const std::string & | rootmapFileName, |
const std::string & | rootmapLibName, | ||
const std::list< std::string > & | classesDefsList, | ||
const std::list< std::string > & | classesNames, | ||
const std::list< std::string > & | nsNames, | ||
const std::list< std::string > & | tdNames, | ||
const std::list< std::string > & | enNames, | ||
const std::list< std::string > & | varNames, | ||
const HeadersDeclsMap_t & | headersClassesMap, | ||
const std::unordered_set< std::string > | headersToIgnore | ||
) |
Generate a rootmap file in the new format, like { decls } namespace A { namespace B { template <typename T> class myTemplate; } }
[libGpad.so libGraf.so libHist.so libMathCore.so] class TAttCanvas class TButton (header1.h header2.h .
. headerN.h) class TMyClass
Definition at line 2251 of file rootcling_impl.cxx.
std::ostream * CreateStreamPtrForSplitDict | ( | const std::string & | dictpathname, |
tempFileNamesCatalog & | tmpCatalog | ||
) |
Transform name of dictionary.
Definition at line 3017 of file rootcling_impl.cxx.
|
static |
Definition at line 180 of file rootcling_impl.cxx.
void EmitStreamerInfo | ( | const char * | normName | ) |
Definition at line 168 of file rootcling_impl.cxx.
|
static |
Definition at line 173 of file rootcling_impl.cxx.
int ExtractAutoloadKeys | ( | std::list< std::string > & | names, |
const COLL & | decls, | ||
const cling::Interpreter & | interp | ||
) |
Definition at line 2223 of file rootcling_impl.cxx.
int ExtractClassesListAndDeclLines | ( | RScanner & | scan, |
std::list< std::string > & | classesList, | ||
std::list< std::string > & | classesListForRootmap, | ||
std::list< std::string > & | fwdDeclarationsList, | ||
const cling::Interpreter & | interpreter | ||
) |
Definition at line 2435 of file rootcling_impl.cxx.
std::string ExtractFileName | ( | const std::string & | path | ) |
Extract the filename from a fullpath.
Definition at line 2144 of file rootcling_impl.cxx.
void ExtractFilePath | ( | const std::string & | path, |
std::string & | dirname | ||
) |
Extract the path from a fullpath finding the last \ or / according to the content in gPathSeparator.
Definition at line 2153 of file rootcling_impl.cxx.
void ExtractHeadersForDecls | ( | const RScanner::ClassColl_t & | annotatedRcds, |
const RScanner::TypedefColl_t | tDefDecls, | ||
const RScanner::FunctionColl_t | funcDecls, | ||
const RScanner::VariableColl_t | varDecls, | ||
const RScanner::EnumColl_t | enumDecls, | ||
HeadersDeclsMap_t & | headersClassesMap, | ||
HeadersDeclsMap_t & | headersDeclsMap, | ||
const cling::Interpreter & | interp | ||
) |
Definition at line 3219 of file rootcling_impl.cxx.
int extractMultipleOptions | ( | std::vector< ROOT::option::Option > & | options, |
int | oIndex, | ||
std::vector< std::string > & | values | ||
) |
Extract from options multiple values with the same option.
Definition at line 5529 of file rootcling_impl.cxx.
void ExtractSelectedNamespaces | ( | RScanner & | scan, |
std::list< std::string > & | nsList | ||
) |
Loop on selected classes and put them in a list.
Definition at line 2572 of file rootcling_impl.cxx.
Make up for skipping RegisterModule, now that dictionary parsing is done and these headers cannot be selected anymore.
Definition at line 2619 of file rootcling_impl.cxx.
|
static |
|
static |
Generates a PCH from the given ModuleGenerator and CompilerInstance.
Returns true iff the PCH was successfully generated.
Definition at line 2035 of file rootcling_impl.cxx.
int GenerateFullDict | ( | std::ostream & | dictStream, |
cling::Interpreter & | interp, | ||
RScanner & | scan, | ||
const ROOT::TMetaUtils::RConstructorTypes & | ctorTypes, | ||
bool | isSplit, | ||
bool | isGenreflex, | ||
bool | isSelXML, | ||
bool | writeEmptyRootPCM | ||
) |
Definition at line 2652 of file rootcling_impl.cxx.
|
static |
Generate the fwd declarations of the selected entities.
Definition at line 3302 of file rootcling_impl.cxx.
void GenerateLinkdef | ( | llvm::cl::list< std::string > & | InputFiles, |
std::string & | code_for_parser | ||
) |
Definition at line 1847 of file rootcling_impl.cxx.
void GenerateNecessaryIncludes | ( | std::ostream & | dictStream, |
const std::string & | includeForSource, | ||
const std::string & | extraIncludes | ||
) |
Definition at line 2862 of file rootcling_impl.cxx.
const std::string GenerateStringFromHeadersForClasses | ( | const HeadersDeclsMap_t & | headersClassesMap, |
const std::string & | detectedUmbrella, | ||
bool | payLoadOnly = false |
||
) |
Generate a string for the dictionary from the headers-classes map.
Definition at line 3378 of file rootcling_impl.cxx.
Translate the arguments of genreflex into rootcling ones and forward them to the RootCling function.
These are two typical genreflex and rootcling commandlines 1) genreflex header1.h [header2.h ...] [options] [preprocessor options] 2) rootcling [-v] [-v0-4] [-f] [out.cxx] [-s sharedlib.so] [-m pcmfilename] header1.h[{+,-}][!] ..headerN.h[{+,-}][!] [{LinkDef.h,selectionRules.xml}] The rules with which the arguments are translated are (1st column genreflex): –debug -v4 –quiet -v0 -o ofile positional arg after -f -s selection file Last argument of the call –fail_on_warning Wrap ROOT::TMetaUtils::Warning and throw if selected
New arguments: -l –library targetLib name (new) -s targetLib name -m pcmname (can be many -m) (new) -m pcmname (can be many -m) –rootmap -rmf (new) –rootmap-lib -rml (new)
genreflex options which rise warnings (feedback is desirable) –no_membertypedefs (it should be irrelevant) –no_templatetypedefs (it should be irrelevant)
genreflex options which are ignored (know for sure they are not needed) –pool, –dataonly –interpreteronly –gccxml{path,opt,post}
Exceptions The –deep option of genreflex is passed as function parameter to rootcling since it's not needed at the moment there.
Definition at line 5610 of file rootcling_impl.cxx.
const char * GetExePath | ( | ) |
Returns the executable path name, used e.g. by SetRootSys().
Definition at line 196 of file rootcling_impl.cxx.
std::pair< std::string, std::string > GetExternalNamespaceAndContainedEntities | ( | const std::string | line | ) |
Performance is not critical here.
Definition at line 2356 of file rootcling_impl.cxx.
size_t GetFullArrayLength | ( | const clang::ConstantArrayType * | arrayType | ) |
Definition at line 417 of file rootcling_impl.cxx.
std::string GetFwdDeclnArgsToKeepString | ( | const ROOT::TMetaUtils::TNormalizedCtxt & | normCtxt, |
cling::Interpreter & | interp | ||
) |
Definition at line 3047 of file rootcling_impl.cxx.
|
static |
Definition at line 4013 of file rootcling_impl.cxx.
void GetMostExternalEnclosingClassName | ( | const clang::DeclContext & | theContext, |
std::string & | ctxtName, | ||
const cling::Interpreter & | interpreter, | ||
bool | treatParent = true |
||
) |
Extract the proper autoload key for nested classes The routine does not erase the name, just updates it.
Definition at line 2195 of file rootcling_impl.cxx.
void GetMostExternalEnclosingClassNameFromDecl | ( | const clang::Decl & | theDecl, |
std::string & | ctxtName, | ||
const cling::Interpreter & | interpreter | ||
) |
Definition at line 2213 of file rootcling_impl.cxx.
string GetNonConstMemberName | ( | const clang::FieldDecl & | m, |
const string & | prefix = "" |
||
) |
Return the name of the data member so that it can be used by non-const operation (so it includes a const_cast if necessary).
Definition at line 830 of file rootcling_impl.cxx.
clang::QualType GetPointeeTypeIfPossible | ( | const clang::QualType & | qt | ) |
Get the pointee type if possible.
Definition at line 3071 of file rootcling_impl.cxx.
const std::string gLibraryExtension | ( | ".so" | ) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
const std::string gPathSeparator | ( | ROOT::TMetaUtils::GetPathSeparator() | ) |
llvm::StringRef GrabIndex | ( | const cling::Interpreter & | interp, |
const clang::FieldDecl & | member, | ||
int | printError | ||
) |
GrabIndex returns a static string (so use it or copy it immediately, do not call GrabIndex twice in the same expression) containing the size of the array data member.
In case of error, or if the size is not specified, GrabIndex returns 0.
Definition at line 1352 of file rootcling_impl.cxx.
|
static |
bool HasPath | ( | const std::string & | name | ) |
Check if file has a path.
Definition at line 2166 of file rootcling_impl.cxx.
|
static |
Includes all given headers in the interpreter.
Returns true when we could include the headers and otherwise false on an error when including.
Definition at line 2048 of file rootcling_impl.cxx.
bool InheritsFromTObject | ( | const clang::RecordDecl * | cl, |
const cling::Interpreter & | interp | ||
) |
Definition at line 431 of file rootcling_impl.cxx.
bool InheritsFromTSelector | ( | const clang::RecordDecl * | cl, |
const cling::Interpreter & | interp | ||
) |
Definition at line 443 of file rootcling_impl.cxx.
|
static |
Write the extra header injected into the module: umbrella header if (umbrella) else content header.
Definition at line 1972 of file rootcling_impl.cxx.
bool IsCorrectClingArgument | ( | const std::string & | argument | ) |
Check if the argument is a sane cling argument.
Performing the following checks: 1) It does not start with "--" and is not the –param option.
Definition at line 3419 of file rootcling_impl.cxx.
bool IsGoodForAutoParseMap | ( | const clang::RecordDecl & | rcd | ) |
Check if the class good for being an autoparse key.
We exclude from this set stl containers of pods/strings TODO: we may use also __gnu_cxx::
Definition at line 3169 of file rootcling_impl.cxx.
bool IsGoodLibraryName | ( | const std::string & | name | ) |
Definition at line 5565 of file rootcling_impl.cxx.
bool IsImplementationName | ( | const std::string & | filename | ) |
Definition at line 3410 of file rootcling_impl.cxx.
bool IsLinkdefFile | ( | const clang::PresumedLoc & | PLoc | ) |
Definition at line 467 of file rootcling_impl.cxx.
bool isPointerToPointer | ( | const clang::FieldDecl & | m | ) |
Definition at line 1152 of file rootcling_impl.cxx.
bool IsSelectionFile | ( | const char * | filename | ) |
Definition at line 474 of file rootcling_impl.cxx.
bool IsSelectionXml | ( | const char * | filename | ) |
Definition at line 454 of file rootcling_impl.cxx.
bool IsSupportedClassName | ( | const char * | name | ) |
Definition at line 3439 of file rootcling_impl.cxx.
void LoadLibraryMap | ( | const std::string & | fileListName, |
map< string, string > & | autoloads | ||
) |
Fill the map of libraries to be loaded in presence of a class Transparently support the old and new rootmap file format.
Definition at line 692 of file rootcling_impl.cxx.
|
static |
Definition at line 3675 of file rootcling_impl.cxx.
|
static |
Returns true iff a given module (and its submodules) contains all headers needed by the given ModuleGenerator.
The names of all header files that are needed by the ModuleGenerator but are not in the given module will be inserted into the MissingHeader variable. Returns true iff the PCH was successfully generated.
Definition at line 3881 of file rootcling_impl.cxx.
bool Namespace__HasMethod | ( | const clang::NamespaceDecl * | cl, |
const char * | name, | ||
const cling::Interpreter & | interp | ||
) |
Definition at line 245 of file rootcling_impl.cxx.
bool NeedsSelection | ( | const char * | name | ) |
Definition at line 3426 of file rootcling_impl.cxx.
bool ParsePragmaLine | ( | const std::string & | line, |
const char * | expectedTokens[], | ||
size_t * | end = nullptr |
||
) |
Check whether the #pragma
line contains expectedTokens (0-terminated array).
Definition at line 549 of file rootcling_impl.cxx.
void ParseRootMapFile | ( | ifstream & | file, |
map< string, string > & | autoloads | ||
) |
Parse the rootmap and add entries to the autoload map.
Definition at line 627 of file rootcling_impl.cxx.
void ParseRootMapFileNewFormat | ( | ifstream & | file, |
map< string, string > & | autoloads | ||
) |
Parse the rootmap and add entries to the autoload map, using the new format.
Definition at line 658 of file rootcling_impl.cxx.
bool ProcessAndAppendIfNotThere | ( | const std::string & | el, |
std::list< std::string > & | el_list, | ||
std::unordered_set< std::string > & | el_set | ||
) |
Separate multiline strings.
Definition at line 2415 of file rootcling_impl.cxx.
std::list< std::string > RecordDecl2Headers | ( | const clang::CXXRecordDecl & | rcd, |
const cling::Interpreter & | interp, | ||
std::set< const clang::CXXRecordDecl * > & | visitedDecls | ||
) |
Extract the list of headers necessary for the Decl.
Definition at line 3086 of file rootcling_impl.cxx.
void RecordDeclCallback | ( | const clang::RecordDecl * | recordDecl | ) |
Definition at line 575 of file rootcling_impl.cxx.
void RiseWarningIfPresent | ( | std::vector< ROOT::option::Option > & | options, |
int | optionIndex, | ||
const char * | descriptor | ||
) |
Definition at line 5552 of file rootcling_impl.cxx.
int ROOT_rootcling_Driver | ( | int | argc, |
char ** | argv, | ||
const ROOT::Internal::RootCling::DriverConfig & | config | ||
) |
Definition at line 6227 of file rootcling_impl.cxx.
Definition at line 4025 of file rootcling_impl.cxx.
void SetRootSys | ( | ) |
Set the ROOTSYS env var based on the executable location.
Definition at line 482 of file rootcling_impl.cxx.
int STLContainerStreamer | ( | const clang::FieldDecl & | m, |
int | rwmode, | ||
const cling::Interpreter & | interp, | ||
const ROOT::TMetaUtils::TNormalizedCtxt & | normCtxt, | ||
std::ostream & | dictStream | ||
) |
Create Streamer code for an STL container.
Returns 1 if data member was an STL container and if Streamer code has been created, 0 otherwise.
Definition at line 855 of file rootcling_impl.cxx.
Create Streamer code for a standard string object.
Returns 1 if data member was a standard string and if Streamer code has been created, 0 otherwise.
Definition at line 1089 of file rootcling_impl.cxx.
void StrcpyArg | ( | string & | dest, |
const char * | original | ||
) |
Copy the command line argument, stripping MODULE/inc if necessary.
Definition at line 1963 of file rootcling_impl.cxx.
bool Which | ( | cling::Interpreter & | interp, |
const char * | fname, | ||
string & | pname | ||
) |
Find file name in path specified via -I statements to Cling.
Return false if the file can not be found. If the file is found, set pname to the full path name and return true.
Definition at line 1903 of file rootcling_impl.cxx.
void WriteArrayDimensions | ( | const clang::QualType & | type, |
std::ostream & | dictStream | ||
) |
Write "[0]" for all but the 1st dimension.
Definition at line 1165 of file rootcling_impl.cxx.
|
static |
Write the AST of the given CompilerInstance to the given File while respecting the given isysroot.
If module is not a null pointer, we only write the given module to the given file and not the whole AST. Returns true if the AST was successfully written.
Definition at line 2001 of file rootcling_impl.cxx.
void WriteAutoStreamer | ( | const ROOT::TMetaUtils::AnnotatedRecordDecl & | cl, |
const cling::Interpreter & | interp, | ||
const ROOT::TMetaUtils::TNormalizedCtxt & | normCtxt, | ||
std::ostream & | dictStream | ||
) |
Definition at line 1780 of file rootcling_impl.cxx.
void WriteClassFunctions | ( | const clang::CXXRecordDecl * | cl, |
std::ostream & | dictStream, | ||
bool | autoLoad = false |
||
) |
Write the code to set the class name and the initialization object.
Definition at line 1180 of file rootcling_impl.cxx.
void WriteNamespaceInit | ( | const clang::NamespaceDecl * | cl, |
cling::Interpreter & | interp, | ||
std::ostream & | dictStream | ||
) |
Write the code to initialize the namespace name and the initialization object.
Definition at line 1257 of file rootcling_impl.cxx.
void WriteStreamer | ( | const ROOT::TMetaUtils::AnnotatedRecordDecl & | cl, |
const cling::Interpreter & | interp, | ||
const ROOT::TMetaUtils::TNormalizedCtxt & | normCtxt, | ||
std::ostream & | dictStream | ||
) |
Definition at line 1390 of file rootcling_impl.cxx.
map<string, string> gAutoloads |
Definition at line 570 of file rootcling_impl.cxx.
bool gBuildingROOT = false |
Definition at line 128 of file rootcling_impl.cxx.
const ROOT::Internal::RootCling::DriverConfig* gDriverConfig = nullptr |
Definition at line 129 of file rootcling_impl.cxx.
string gLibsNeeded |
Definition at line 571 of file rootcling_impl.cxx.