[Scummvm-git-logs] scummvm master -> cf8022dd2793d12aa8423c769cca7883baa7723b

orgads noreply at scummvm.org
Fri Jan 3 07:30:30 UTC 2025


This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
c9c2ffd88b JANITORIAL: Require semicolon after COMMON_SPAN_TYPEDEFS macro use
cf8022dd27 JANITORIAL: Use `default` for span ctors


Commit: c9c2ffd88bd8ab9befbc608cd1a8fcec7e69e7a1
    https://github.com/scummvm/scummvm/commit/c9c2ffd88bd8ab9befbc608cd1a8fcec7e69e7a1
Author: Orgad Shaneh (orgads at gmail.com)
Date: 2025-01-03T09:30:16+02:00

Commit Message:
JANITORIAL: Require semicolon after COMMON_SPAN_TYPEDEFS macro use

Changed paths:
    common/span.h
    engines/sci/util.h
    test/common/span.h


diff --git a/common/span.h b/common/span.h
index 3fbdfd1538a..9eb08c2a7de 100644
--- a/common/span.h
+++ b/common/span.h
@@ -40,7 +40,7 @@ namespace Common {
 	typedef typename super_type::pointer pointer; \
 	typedef typename super_type::const_pointer const_pointer; \
 	typedef typename super_type::reference reference; \
-	typedef typename super_type::const_reference const_reference;
+	typedef typename super_type::const_reference const_reference
 
 enum : uint {
 	kSpanMaxSize = 0xFFFFFFFF,
@@ -542,7 +542,7 @@ class SpanImpl : public SpanBase<ValueType, Derived> {
 #endif
 
 public:
-	COMMON_SPAN_TYPEDEFS
+	COMMON_SPAN_TYPEDEFS;
 
 	inline SpanImpl() : super_type(), _data(nullptr), _size(0) {}
 
@@ -694,7 +694,7 @@ class Span : public SpanImpl<ValueType, Span> {
 	template <typename T> friend class Span;
 
 public:
-	COMMON_SPAN_TYPEDEFS
+	COMMON_SPAN_TYPEDEFS;
 
 	inline Span() : super_type() {}
 
@@ -721,7 +721,7 @@ class NamedSpanImpl : public SpanImpl<ValueType, Derived> {
 #endif
 
 public:
-	COMMON_SPAN_TYPEDEFS
+	COMMON_SPAN_TYPEDEFS;
 
 	inline NamedSpanImpl() : super_type(), _name(), _sourceByteOffset(0) {}
 
@@ -867,7 +867,7 @@ class NamedSpan : public NamedSpanImpl<ValueType, NamedSpan> {
 	template <typename T> friend class NamedSpan;
 
 public:
-	COMMON_SPAN_TYPEDEFS
+	COMMON_SPAN_TYPEDEFS;
 
 	inline NamedSpan() : super_type() {}
 
diff --git a/engines/sci/util.h b/engines/sci/util.h
index c837cefe5cf..98a85c07707 100644
--- a/engines/sci/util.h
+++ b/engines/sci/util.h
@@ -252,7 +252,7 @@ class SciSpan : public SciSpanImpl<ValueType, SciSpan> {
 	typedef SciSpanImpl<ValueType, ::Sci::SciSpan> super_type;
 
 public:
-	COMMON_SPAN_TYPEDEFS
+	COMMON_SPAN_TYPEDEFS;
 
 	inline SciSpan() : super_type() {}
 
diff --git a/test/common/span.h b/test/common/span.h
index 7e6e2e24625..956efc0818b 100644
--- a/test/common/span.h
+++ b/test/common/span.h
@@ -14,7 +14,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 	class SiblingSpanImpl : public Common::SpanImpl<ValueType, Derived> {
 		typedef Common::SpanImpl<ValueType, Derived> super_type;
 	public:
-		COMMON_SPAN_TYPEDEFS
+		COMMON_SPAN_TYPEDEFS;
 		SiblingSpanImpl() : super_type() {}
 		SiblingSpanImpl(pointer data_, size_type size_) : super_type(data_, size_) {}
 	};
@@ -23,7 +23,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 	class SiblingSpan : public SiblingSpanImpl<ValueType, SiblingSpan> {
 		typedef SiblingSpanImpl<ValueType, ::SpanTestSuite::SiblingSpan> super_type;
 	public:
-		COMMON_SPAN_TYPEDEFS
+		COMMON_SPAN_TYPEDEFS;
 		SiblingSpan() : super_type() {}
 		SiblingSpan(pointer data_, size_type size_) : super_type(data_, size_) {}
 	};
@@ -32,7 +32,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 	class SubSpanImpl : public Common::NamedSpanImpl<ValueType, Derived> {
 		typedef Common::NamedSpanImpl<ValueType, Derived> super_type;
 	public:
-		COMMON_SPAN_TYPEDEFS
+		COMMON_SPAN_TYPEDEFS;
 		SubSpanImpl() : super_type() {}
 		SubSpanImpl(pointer data_,
 					size_type size_,
@@ -48,7 +48,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 	class SubSpan : public SubSpanImpl<ValueType, SubSpan> {
 		typedef SubSpanImpl<ValueType, ::SpanTestSuite::SubSpan> super_type;
 	public:
-		COMMON_SPAN_TYPEDEFS
+		COMMON_SPAN_TYPEDEFS;
 		SubSpan() : super_type() {}
 		SubSpan(pointer data_,
 				size_type size_,


Commit: cf8022dd2793d12aa8423c769cca7883baa7723b
    https://github.com/scummvm/scummvm/commit/cf8022dd2793d12aa8423c769cca7883baa7723b
Author: Orgad Shaneh (orgads at gmail.com)
Date: 2025-01-03T09:30:16+02:00

Commit Message:
JANITORIAL: Use `default` for span ctors

Changed paths:
    common/span.h
    engines/sci/util.h
    test/common/span.h


diff --git a/common/span.h b/common/span.h
index 9eb08c2a7de..515d712b34f 100644
--- a/common/span.h
+++ b/common/span.h
@@ -723,7 +723,7 @@ class NamedSpanImpl : public SpanImpl<ValueType, Derived> {
 public:
 	COMMON_SPAN_TYPEDEFS;
 
-	inline NamedSpanImpl() : super_type(), _name(), _sourceByteOffset(0) {}
+	inline NamedSpanImpl() = default;
 
 	inline NamedSpanImpl(const pointer data_,
 						 const size_type size_,
@@ -753,7 +753,7 @@ public:
 
 private:
 	String _name;
-	size_type _sourceByteOffset;
+	size_type _sourceByteOffset = 0;
 
 #pragma mark -
 #pragma mark NamedSpanImpl - Subspan
@@ -869,7 +869,7 @@ class NamedSpan : public NamedSpanImpl<ValueType, NamedSpan> {
 public:
 	COMMON_SPAN_TYPEDEFS;
 
-	inline NamedSpan() : super_type() {}
+	inline NamedSpan() = default;
 
 	inline NamedSpan(const pointer data_,
 					 const size_type size_,
diff --git a/engines/sci/util.h b/engines/sci/util.h
index 98a85c07707..120369c0a5e 100644
--- a/engines/sci/util.h
+++ b/engines/sci/util.h
@@ -254,7 +254,7 @@ class SciSpan : public SciSpanImpl<ValueType, SciSpan> {
 public:
 	COMMON_SPAN_TYPEDEFS;
 
-	inline SciSpan() : super_type() {}
+	inline SciSpan() = default;
 
 	inline SciSpan(const pointer data_,
 				   const size_type size_,
diff --git a/test/common/span.h b/test/common/span.h
index 956efc0818b..a19c33fca2c 100644
--- a/test/common/span.h
+++ b/test/common/span.h
@@ -15,7 +15,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 		typedef Common::SpanImpl<ValueType, Derived> super_type;
 	public:
 		COMMON_SPAN_TYPEDEFS;
-		SiblingSpanImpl() : super_type() {}
+		SiblingSpanImpl() = default;
 		SiblingSpanImpl(pointer data_, size_type size_) : super_type(data_, size_) {}
 	};
 
@@ -24,7 +24,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 		typedef SiblingSpanImpl<ValueType, ::SpanTestSuite::SiblingSpan> super_type;
 	public:
 		COMMON_SPAN_TYPEDEFS;
-		SiblingSpan() : super_type() {}
+		SiblingSpan() = default;
 		SiblingSpan(pointer data_, size_type size_) : super_type(data_, size_) {}
 	};
 
@@ -33,7 +33,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 		typedef Common::NamedSpanImpl<ValueType, Derived> super_type;
 	public:
 		COMMON_SPAN_TYPEDEFS;
-		SubSpanImpl() : super_type() {}
+		SubSpanImpl() = default;
 		SubSpanImpl(pointer data_,
 					size_type size_,
 					const Common::String &name_ = Common::String(),
@@ -49,7 +49,7 @@ class SpanTestSuite : public CxxTest::TestSuite {
 		typedef SubSpanImpl<ValueType, ::SpanTestSuite::SubSpan> super_type;
 	public:
 		COMMON_SPAN_TYPEDEFS;
-		SubSpan() : super_type() {}
+		SubSpan() = default;
 		SubSpan(pointer data_,
 				size_type size_,
 				const Common::String &name_ = Common::String(),




More information about the Scummvm-git-logs mailing list