From 31138ff7729cbf179079a5e635d3a823e2971f08 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 12 Oct 2018 14:48:15 +0200 Subject: loplugin:constfields in package..registry Change-Id: Ie139490f2b008bf294910d002af711f8f41fe76d Reviewed-on: https://gerrit.libreoffice.org/61727 Tested-by: Jenkins Reviewed-by: Noel Grandin --- registry/source/keyimpl.hxx | 2 +- registry/source/reflread.cxx | 14 +++++++------- registry/source/reflwrit.cxx | 24 ++++++++++++------------ 3 files changed, 20 insertions(+), 20 deletions(-) (limited to 'registry/source') diff --git a/registry/source/keyimpl.hxx b/registry/source/keyimpl.hxx index 27043d2cc223..d5c6ada33395 100644 --- a/registry/source/keyimpl.hxx +++ b/registry/source/keyimpl.hxx @@ -125,7 +125,7 @@ public: private: sal_uInt32 m_refCount; - OUString m_name; + OUString const m_name; bool m_bDeleted:1; bool m_bModified:1; ORegistry* m_pRegistry; diff --git a/registry/source/reflread.cxx b/registry/source/reflread.cxx index c459bab9a8fb..1b0345145989 100644 --- a/registry/source/reflread.cxx +++ b/registry/source/reflread.cxx @@ -213,7 +213,7 @@ class ConstantPool : public BlopObject { public: - sal_uInt16 m_numOfEntries; + sal_uInt16 const m_numOfEntries; std::unique_ptr m_pIndex; // index values may be < 0 for cached string constants std::unique_ptr m_pStringCache; @@ -529,9 +529,9 @@ class FieldList : public BlopObject { public: - sal_uInt16 m_numOfEntries; + sal_uInt16 const m_numOfEntries; size_t m_FIELD_ENTRY_SIZE; - ConstantPool* m_pCP; + ConstantPool* const m_pCP; FieldList(const sal_uInt8* buffer, sal_uInt32 len, sal_uInt16 numEntries, ConstantPool* pCP) : BlopObject(buffer, len) @@ -713,9 +713,9 @@ class ReferenceList : public BlopObject { public: - sal_uInt16 m_numOfEntries; + sal_uInt16 const m_numOfEntries; size_t m_REFERENCE_ENTRY_SIZE; - ConstantPool* m_pCP; + ConstantPool* const m_pCP; ReferenceList(const sal_uInt8* buffer, sal_uInt32 len, sal_uInt16 numEntries, ConstantPool* pCP) : BlopObject(buffer, len) @@ -813,10 +813,10 @@ class MethodList : public BlopObject { public: - sal_uInt16 m_numOfEntries; + sal_uInt16 const m_numOfEntries; size_t m_PARAM_ENTRY_SIZE; std::unique_ptr m_pIndex; - ConstantPool* m_pCP; + ConstantPool* const m_pCP; MethodList(const sal_uInt8* buffer, sal_uInt32 len, sal_uInt16 numEntries, ConstantPool* pCP) : BlopObject(buffer, len) diff --git a/registry/source/reflwrit.cxx b/registry/source/reflwrit.cxx index 53476430287f..67a5b2552ff5 100644 --- a/registry/source/reflwrit.cxx +++ b/registry/source/reflwrit.cxx @@ -138,8 +138,8 @@ sal_uInt32 writeDouble(sal_uInt8* buffer, double v) double v; struct { - sal_uInt32 b1; - sal_uInt32 b2; + sal_uInt32 b1; + sal_uInt32 b2; } b; } x; @@ -175,7 +175,7 @@ sal_uInt32 writeDouble(sal_uInt8* buffer, double v) struct CPInfo { - CPInfoTag m_tag; + CPInfoTag const m_tag; union { const sal_Char* aUtf8; @@ -619,19 +619,19 @@ class TypeWriter public: sal_uInt32 m_refCount; - typereg_Version m_version; - RTTypeClass m_typeClass; - OString m_typeName; - sal_uInt16 m_nSuperTypes; + typereg_Version const m_version; + RTTypeClass const m_typeClass; + OString const m_typeName; + sal_uInt16 const m_nSuperTypes; std::unique_ptr m_superTypeNames; - OString m_doku; - OString m_fileName; - sal_uInt16 m_fieldCount; + OString const m_doku; + OString const m_fileName; + sal_uInt16 const m_fieldCount; FieldEntry* m_fields; - sal_uInt16 m_methodCount; + sal_uInt16 const m_methodCount; MethodEntry* m_methods; - sal_uInt16 m_referenceCount; + sal_uInt16 const m_referenceCount; ReferenceEntry* m_references; std::unique_ptr m_blop; -- cgit