Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions tree/treeplayer/inc/TTreeReaderArray.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class TTreeReaderArrayBase : public TTreeReaderValueBase {
std::size_t GetValueSize() const { return fImpl ? fImpl->GetValueSize(GetProxy()) : 0; }

protected:
TTreeReaderArrayBase() = default;
void *UntypedAt(std::size_t idx) const { return fImpl->At(GetProxy(), idx); }
void CreateProxy() override;
bool GetBranchAndLeaf(TBranch *&branch, TLeaf *&myLeaf, TDictionary *&branchActualType,
Expand All @@ -52,8 +53,8 @@ class TTreeReaderArrayBase : public TTreeReaderValueBase {

std::unique_ptr<TVirtualCollectionReader> fImpl; // Common interface to collections

// FIXME: re-introduce once we have ClassDefInline!
// ClassDefOverride(TTreeReaderArrayBase, 0);//Accessor to member of an object stored in a collection
ClassDefInlineOverride(TTreeReaderArrayBase, 0);//Accessor to member of an object stored in a collection
friend class ClassDefGenerateInitInstanceLocalInjector<TTreeReaderArrayBase>;
};

class R__CLING_PTRCHECK(off) TTreeReaderUntypedArray final : public TTreeReaderArrayBase {
Expand Down Expand Up @@ -241,8 +242,7 @@ class R__CLING_PTRCHECK(off) TTreeReaderArray final : public ROOT::Internal::TTr
#define R__TTreeReaderArray_TypeString(T) #T
const char *GetDerivedTypeName() const override { return R__TTreeReaderArray_TypeString(T); }
#undef R__TTreeReaderArray_TypeString
// FIXME: re-introduce once we have ClassDefTInline!
// ClassDefT(TTreeReaderArray, 0);//Accessor to member of an object stored in a collection
ClassDefInlineOverride(TTreeReaderArray, 0);//Accessor to member of an object stored in a collection
};

namespace cling {
Expand Down
13 changes: 6 additions & 7 deletions tree/treeplayer/inc/TTreeReaderValue.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ class TTreeReaderValueBase {
virtual ~TTreeReaderValueBase();

protected:
TTreeReaderValueBase() = default;
TTreeReaderValueBase(TTreeReader *reader, const char *branchname, TDictionary *dict, bool opaqueRead = false);
TTreeReaderValueBase(const TTreeReaderValueBase &);
TTreeReaderValueBase &operator=(const TTreeReaderValueBase &);
Expand All @@ -114,7 +115,7 @@ class TTreeReaderValueBase {
virtual void CreateProxy();
static const char *GetBranchDataType(TBranch *branch, TDictionary *&dict, TDictionary const *curDict);

virtual const char *GetDerivedTypeName() const = 0;
virtual const char *GetDerivedTypeName() const { return nullptr; };

Detail::TBranchProxy *GetProxy() const { return fProxy; }

Expand Down Expand Up @@ -150,9 +151,8 @@ class TTreeReaderValueBase {
*/
bool fOpaqueRead{false};

// FIXME: re-introduce once we have ClassDefInline!
// ClassDefOverride(TTreeReaderValueBase, 0);//Base class for accessors to data via TTreeReader

ClassDefInline(TTreeReaderValueBase, 0);//Base class for accessors to data via TTreeReader
friend class ClassDefGenerateInitInstanceLocalInjector<TTreeReaderValueBase>;
friend class ::TTreeReader;
};

Expand Down Expand Up @@ -238,16 +238,15 @@ class R__CLING_PTRCHECK(off) TTreeReaderValue final : public ROOT::Internal::TTr
T &operator*() { return *Get(); }

protected:
// FIXME: use IsA() instead once we have ClassDefTInline
// FIXME: use IsA() instead
/// Get the template argument as a string.
const char *GetDerivedTypeName() const override
{
static const std::string sElementTypeName = GetElementTypeName(typeid(T));
return sElementTypeName.data();
}

// FIXME: re-introduce once we have ClassDefTInline!
// ClassDefT(TTreeReaderValue, 0);//Accessor to data via TTreeReader
ClassDefInlineOverride(TTreeReaderValue, 0);//Accessor to data via TTreeReader
};

namespace cling {
Expand Down
Loading