From 6cb9e6dad798ec59f055aebe84a9c4a21e4be40d Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Fri, 3 Mar 2017 20:57:02 +0100 Subject: Remove redundant 'inline' keyword ...from function definitions occurring within class definitions. Done with a rewriting Clang plugin (to be pushed later). Change-Id: I9c6f2818a57ccdb361548895a7743107cbacdff8 Reviewed-on: https://gerrit.libreoffice.org/34874 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- include/xmlreader/span.hxx | 16 ++++++++-------- include/xmlreader/xmlreader.hxx | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) (limited to 'include/xmlreader') diff --git a/include/xmlreader/span.hxx b/include/xmlreader/span.hxx index 1d8bc838dc44..1f4630efca42 100644 --- a/include/xmlreader/span.hxx +++ b/include/xmlreader/span.hxx @@ -35,32 +35,32 @@ struct SAL_WARN_UNUSED OOO_DLLPUBLIC_XMLREADER Span { char const * begin; sal_Int32 length; - inline Span(): begin(nullptr), length(0) {} + Span(): begin(nullptr), length(0) {} // init length to avoid compiler warnings - inline Span(char const * theBegin, sal_Int32 theLength): + Span(char const * theBegin, sal_Int32 theLength): begin(theBegin), length(theLength) {} - template< std::size_t N > explicit inline Span(char const (& literal)[N]): + template< std::size_t N > explicit Span(char const (& literal)[N]): begin(literal), length(N - 1) {} - inline void clear() throw() { begin = nullptr; } + void clear() throw() { begin = nullptr; } - inline bool is() const { return begin != nullptr; } + bool is() const { return begin != nullptr; } - inline bool equals(Span const & text) const { + bool equals(Span const & text) const { return length == text.length && (rtl_str_compare_WithLength( begin, length, text.begin, text.length) == 0); } - inline bool equals(char const * textBegin, sal_Int32 textLength) const { + bool equals(char const * textBegin, sal_Int32 textLength) const { return equals(Span(textBegin, textLength)); } - template< std::size_t N > inline bool equals(char const (& literal)[N]) + template< std::size_t N > bool equals(char const (& literal)[N]) const { return equals(Span(literal, N - 1)); diff --git a/include/xmlreader/xmlreader.hxx b/include/xmlreader/xmlreader.hxx index c25c456c8983..364590b05243 100644 --- a/include/xmlreader/xmlreader.hxx +++ b/include/xmlreader/xmlreader.hxx @@ -129,9 +129,9 @@ private: enum class State { Content, StartTag, EndTag, EmptyElementTag, Done }; - SAL_DLLPRIVATE inline char read() { return pos_ == end_ ? '\0' : *pos_++; } + SAL_DLLPRIVATE char read() { return pos_ == end_ ? '\0' : *pos_++; } - SAL_DLLPRIVATE inline char peek() { return pos_ == end_ ? '\0' : *pos_; } + SAL_DLLPRIVATE char peek() { return pos_ == end_ ? '\0' : *pos_; } SAL_DLLPRIVATE void normalizeLineEnds(Span const & text); -- cgit