From 64158376f5a62b1bb541cbeec983d4db51344c25 Mon Sep 17 00:00:00 2001 From: Michael Davidsaver Date: Tue, 31 Jul 2018 15:35:45 -0700 Subject: [PATCH] PVStructure inline access to member variables --- src/factory/PVStructure.cpp | 14 +------------- src/pv/pvData.h | 4 ++-- 2 files changed, 3 insertions(+), 15 deletions(-) diff --git a/src/factory/PVStructure.cpp b/src/factory/PVStructure.cpp index 166440e..75447f4 100644 --- a/src/factory/PVStructure.cpp +++ b/src/factory/PVStructure.cpp @@ -60,9 +60,7 @@ PVStructure::PVStructure(StructureConstPtr const & structurePtr, } } -PVStructure::~PVStructure() -{ -} +PVStructure::~PVStructure() {} void PVStructure::setImmutable() { @@ -74,16 +72,6 @@ void PVStructure::setImmutable() PVField::setImmutable(); } -const StructureConstPtr& PVStructure::getStructure() const -{ - return structurePtr; -} - -const PVFieldPtrArray & PVStructure::getPVFields() const -{ - return pvFields; -} - PVFieldPtr PVStructure::getSubFieldImpl(size_t fieldOffset, bool throws) const { const PVStructure *current = this; diff --git a/src/pv/pvData.h b/src/pv/pvData.h index 31934c6..ccfb6b4 100644 --- a/src/pv/pvData.h +++ b/src/pv/pvData.h @@ -747,12 +747,12 @@ public: * Get the introspection interface * @return The interface. */ - const StructureConstPtr &getStructure() const; + inline const StructureConstPtr &getStructure() const { return structurePtr; } /** * Get the array of pointers to the subfields in the structure. * @return The array. */ - const PVFieldPtrArray & getPVFields() const; + inline const PVFieldPtrArray & getPVFields() const { return pvFields; } /** * Get the subfield with the specified offset.