diff options
author | Moonchild <mcwerewolf@gmail.com> | 2018-09-16 12:01:55 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-16 12:01:55 +0200 |
commit | 08dd8ff76063097d7ceea3ec2877028e57ede211 (patch) | |
tree | 467ec1506f7889c2faeb0280b8c7de4adc4abe7b /js/src/wasm/AsmJS.cpp | |
parent | 351ffa462d2314c4b60369e2ba0f13b5d90f03b5 (diff) | |
parent | 0712ac7f81a455b21e0065b6a212b64385835e5e (diff) | |
download | UXP-08dd8ff76063097d7ceea3ec2877028e57ede211.tar UXP-08dd8ff76063097d7ceea3ec2877028e57ede211.tar.gz UXP-08dd8ff76063097d7ceea3ec2877028e57ede211.tar.lz UXP-08dd8ff76063097d7ceea3ec2877028e57ede211.tar.xz UXP-08dd8ff76063097d7ceea3ec2877028e57ede211.zip |
Merge pull request #767 from trav90/class-memaccess-errors
Fix more -Wclass-memaccess warnings (part 2)
Diffstat (limited to 'js/src/wasm/AsmJS.cpp')
-rw-r--r-- | js/src/wasm/AsmJS.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/js/src/wasm/AsmJS.cpp b/js/src/wasm/AsmJS.cpp index 7fade24fb..2237d1d7f 100644 --- a/js/src/wasm/AsmJS.cpp +++ b/js/src/wasm/AsmJS.cpp @@ -249,14 +249,14 @@ typedef Vector<AsmJSImport, 0, SystemAllocPolicy> AsmJSImportVector; // case the function is toString()ed. class AsmJSExport { - uint32_t funcIndex_; + uint32_t funcIndex_ = 0; // All fields are treated as cacheable POD: - uint32_t startOffsetInModule_; // Store module-start-relative offsets - uint32_t endOffsetInModule_; // so preserved by serialization. + uint32_t startOffsetInModule_ = 0; // Store module-start-relative offsets + uint32_t endOffsetInModule_ = 0; // so preserved by serialization. public: - AsmJSExport() { PodZero(this); } + AsmJSExport() = default; AsmJSExport(uint32_t funcIndex, uint32_t startOffsetInModule, uint32_t endOffsetInModule) : funcIndex_(funcIndex), startOffsetInModule_(startOffsetInModule), @@ -288,12 +288,12 @@ enum class CacheResult struct AsmJSMetadataCacheablePod { - uint32_t numFFIs; - uint32_t srcLength; - uint32_t srcLengthWithRightBrace; - bool usesSimd; + uint32_t numFFIs = 0; + uint32_t srcLength = 0; + uint32_t srcLengthWithRightBrace = 0; + bool usesSimd = false; - AsmJSMetadataCacheablePod() { PodZero(this); } + AsmJSMetadataCacheablePod() = default; }; struct js::AsmJSMetadata : Metadata, AsmJSMetadataCacheablePod |