summaryrefslogtreecommitdiff
path: root/js/public/Utility.h
diff options
context:
space:
mode:
Diffstat (limited to 'js/public/Utility.h')
-rw-r--r--js/public/Utility.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/js/public/Utility.h b/js/public/Utility.h
index dbe69e18c0..e641c6097b 100644
--- a/js/public/Utility.h
+++ b/js/public/Utility.h
@@ -352,7 +352,7 @@ namespace js {
* instances of type |T|. Return false if the calculation overflowed.
*/
template <typename T>
-MOZ_MUST_USE inline bool
+[[nodiscard]] inline bool
CalculateAllocSize(size_t numElems, size_t* bytesOut)
{
*bytesOut = numElems * sizeof(T);
@@ -365,7 +365,7 @@ CalculateAllocSize(size_t numElems, size_t* bytesOut)
* false if the calculation overflowed.
*/
template <typename T, typename Extra>
-MOZ_MUST_USE inline bool
+[[nodiscard]] inline bool
CalculateAllocSizeWithExtra(size_t numExtra, size_t* bytesOut)
{
*bytesOut = sizeof(T) + numExtra * sizeof(Extra);