Bug 1270805 - add default constructor for TypeAndValue<Nothing>. r?jdemooij
MozReview-Commit-ID: HqSkqzYGIGc
--- a/js/src/asmjs/WasmBinaryIterator.h
+++ b/js/src/asmjs/WasmBinaryIterator.h
@@ -167,22 +167,22 @@ class TypeAndValue
}
void setValue(Value value) {
value_ = value;
}
};
// Specialization for when there is no additional data needed.
template <>
-struct TypeAndValue<Nothing>
+class TypeAndValue<Nothing>
{
ExprType type_;
public:
- TypeAndValue() {}
+ TypeAndValue() = default;
explicit TypeAndValue(ExprType type) : type_(type) {}
TypeAndValue(ExprType type, Nothing value)
: type_(type)
{}
ExprType type() const { return type_; }
Nothing value() const { return Nothing(); }