diff options
author | Moonchild <moonchild@palemoon.org> | 2023-11-11 14:27:03 +0100 |
---|---|---|
committer | Moonchild <moonchild@palemoon.org> | 2023-11-11 14:27:03 +0100 |
commit | 734f0957fb8bc06ae6e5105d878f1b7007ce8b5d (patch) | |
tree | df73c5d270de365b4035aff74ef703c9f922bd30 /xpcom | |
parent | c789882a294d29b3e5450a972ad67c4839c75e23 (diff) | |
download | uxp-734f0957fb8bc06ae6e5105d878f1b7007ce8b5d.tar.gz |
Issue #2343 - replace MOZ_FALLTHROUGH with [[fallthrough]]
Basically a S&R. Removed the macro and adjusts IDL codegen accordingly.
Diffstat (limited to 'xpcom')
-rw-r--r-- | xpcom/base/nsDebugImpl.cpp | 2 | ||||
-rw-r--r-- | xpcom/ds/nsCheapSets.h | 2 | ||||
-rw-r--r-- | xpcom/ds/nsPersistentProperties.cpp | 2 | ||||
-rw-r--r-- | xpcom/ds/nsVariant.cpp | 4 | ||||
-rw-r--r-- | xpcom/glue/nsTextFormatter.cpp | 4 | ||||
-rw-r--r-- | xpcom/io/nsWildCard.cpp | 4 |
6 files changed, 9 insertions, 9 deletions
diff --git a/xpcom/base/nsDebugImpl.cpp b/xpcom/base/nsDebugImpl.cpp index c4d4437a9b..48b7e8e018 100644 --- a/xpcom/base/nsDebugImpl.cpp +++ b/xpcom/base/nsDebugImpl.cpp @@ -402,7 +402,7 @@ NS_DebugBreak(uint32_t aSeverity, const char* aStr, const char* aExpr, case NS_ASSERT_STACK_AND_ABORT: nsTraceRefcnt::WalkTheStack(stderr); // Fall through to abort - MOZ_FALLTHROUGH; + [[fallthrough]]; case NS_ASSERT_ABORT: Abort(buf.buffer); diff --git a/xpcom/ds/nsCheapSets.h b/xpcom/ds/nsCheapSets.h index c2375b85f2..1d5aa21a8f 100644 --- a/xpcom/ds/nsCheapSets.h +++ b/xpcom/ds/nsCheapSets.h @@ -134,7 +134,7 @@ nsCheapSet<EntryType>::Put(const KeyType aVal) mUnion.table = table; mState = MANY; } - MOZ_FALLTHROUGH; + [[fallthrough]]; case MANY: mUnion.table->PutEntry(aVal); diff --git a/xpcom/ds/nsPersistentProperties.cpp b/xpcom/ds/nsPersistentProperties.cpp index 4bbaac905d..50295984ac 100644 --- a/xpcom/ds/nsPersistentProperties.cpp +++ b/xpcom/ds/nsPersistentProperties.cpp @@ -226,7 +226,7 @@ nsPropertiesParser::ParseValueCharacter(char16_t aChar, const char16_t* aCur, aTokenStart = aCur + 1; break; } - MOZ_FALLTHROUGH; + [[fallthrough]]; case '\r': // we're done! We have a key and value diff --git a/xpcom/ds/nsVariant.cpp b/xpcom/ds/nsVariant.cpp index 7e797117ad..ffec2575f0 100644 --- a/xpcom/ds/nsVariant.cpp +++ b/xpcom/ds/nsVariant.cpp @@ -355,7 +355,7 @@ CloneArray(uint16_t aInType, const nsIID* aInIID, if (aOutIID) { *aOutIID = *aInIID; } - MOZ_FALLTHROUGH; + [[fallthrough]]; case nsIDataType::VTYPE_INTERFACE: { memcpy(*aOutValue, aInValue, allocSize); @@ -759,7 +759,7 @@ nsDiscriminatedUnion::ToString(nsACString& aOutString) const case nsIDataType::VTYPE_WSTRING_SIZE_IS: case nsIDataType::VTYPE_WCHAR: NS_ERROR("ToString being called for a string type - screwy logic!"); - MOZ_FALLTHROUGH; + [[fallthrough]]; // XXX We might want stringified versions of these... ??? diff --git a/xpcom/glue/nsTextFormatter.cpp b/xpcom/glue/nsTextFormatter.cpp index 96cd85712d..1c3f60fb90 100644 --- a/xpcom/glue/nsTextFormatter.cpp +++ b/xpcom/glue/nsTextFormatter.cpp @@ -352,14 +352,14 @@ cvt_f(SprintfState* aState, double aDouble, int aWidth, int aPrec, break; case 'E': exp = 'E'; - MOZ_FALLTHROUGH; + [[fallthrough]]; case 'e': numdigits = aPrec + 1; mode = 2; break; case 'G': exp = 'E'; - MOZ_FALLTHROUGH; + [[fallthrough]]; case 'g': if (aPrec == 0) { aPrec = 1; diff --git a/xpcom/io/nsWildCard.cpp b/xpcom/io/nsWildCard.cpp index 1250a41618..18c58810fd 100644 --- a/xpcom/io/nsWildCard.cpp +++ b/xpcom/io/nsWildCard.cpp @@ -80,7 +80,7 @@ _valid_subexp(const T* aExpr, T aStop1, T aStop2) return INVALID_SXP; } ++tld; - MOZ_FALLTHROUGH; + [[fallthrough]]; case '*': case '?': case '$': @@ -396,7 +396,7 @@ _shexp_match(const T* aStr, const T* aExpr, bool aCaseInsensitive, return ABORTED; case '\\': ++y; - MOZ_FALLTHROUGH; + [[fallthrough]]; default: if (aCaseInsensitive) { if (::upper(aStr[x]) != ::upper(aExpr[y])) { |