summaryrefslogtreecommitdiff
path: root/js/src/wasm/AsmJS.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/wasm/AsmJS.cpp')
-rw-r--r--js/src/wasm/AsmJS.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/js/src/wasm/AsmJS.cpp b/js/src/wasm/AsmJS.cpp
index 9bb3f08e79..1c42ceca59 100644
--- a/js/src/wasm/AsmJS.cpp
+++ b/js/src/wasm/AsmJS.cpp
@@ -1595,7 +1595,7 @@ class MOZ_STACK_CLASS ModuleValidator
MOZ_ASSERT(!moduleFunctionName_);
moduleFunctionName_ = name;
}
- MOZ_MUST_USE bool initGlobalArgumentName(PropertyName* n) {
+ [[nodiscard]] bool initGlobalArgumentName(PropertyName* n) {
MOZ_ASSERT(n->isTenured());
globalArgumentName_ = n;
if (n) {
@@ -1605,7 +1605,7 @@ class MOZ_STACK_CLASS ModuleValidator
}
return true;
}
- MOZ_MUST_USE bool initImportArgumentName(PropertyName* n) {
+ [[nodiscard]] bool initImportArgumentName(PropertyName* n) {
MOZ_ASSERT(n->isTenured());
importArgumentName_ = n;
if (n) {
@@ -1615,7 +1615,7 @@ class MOZ_STACK_CLASS ModuleValidator
}
return true;
}
- MOZ_MUST_USE bool initBufferArgumentName(PropertyName* n) {
+ [[nodiscard]] bool initBufferArgumentName(PropertyName* n) {
MOZ_ASSERT(n->isTenured());
bufferArgumentName_ = n;
if (n) {
@@ -2500,11 +2500,11 @@ class MOZ_STACK_CLASS FunctionValidator
Encoder& encoder() { return *encoder_; }
- MOZ_MUST_USE bool writeInt32Lit(int32_t i32) {
+ [[nodiscard]] bool writeInt32Lit(int32_t i32) {
return encoder().writeOp(Op::I32Const) &&
encoder().writeVarS32(i32);
}
- MOZ_MUST_USE bool writeConstExpr(const NumLit& lit) {
+ [[nodiscard]] bool writeConstExpr(const NumLit& lit) {
switch (lit.which()) {
case NumLit::Fixnum:
case NumLit::NegativeInt:
@@ -2521,11 +2521,11 @@ class MOZ_STACK_CLASS FunctionValidator
}
MOZ_CRASH("unexpected literal type");
}
- MOZ_MUST_USE bool writeCall(ParseNode* pn, Op op) {
+ [[nodiscard]] bool writeCall(ParseNode* pn, Op op) {
return encoder().writeOp(op) &&
fg_.addCallSiteLineNum(m().tokenStream().srcCoords.lineNum(pn->pn_pos.begin));
}
- MOZ_MUST_USE bool prepareCall(ParseNode* pn) {
+ [[nodiscard]] bool prepareCall(ParseNode* pn) {
return fg_.addCallSiteLineNum(m().tokenStream().srcCoords.lineNum(pn->pn_pos.begin));
}
};