Closed Bug 1493692 Opened 7 years ago Closed 7 years ago

Remove enum code confusion in readReferenceType

Categories

(Core :: JavaScript: WebAssembly, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
mozilla64
Tracking Status
firefox64 --- fixed

People

(Reporter: lth, Assigned: lth)

Details

Attachments

(1 file)

readReferenceType compares the value that was read to a TypeCode but then casts it to a ValType::Code. This is correct, because those two enums are equivalent by construction, but it is unnecessarily confusing. The value that was read can just be compared to a ValType::Code instead.
Attachment #9011471 - Flags: review?(luke)
Attachment #9011471 - Flags: review?(luke) → review+
Pushed by lhansen@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/01a28ef7dd35 use ValType::Code to validate type code. r=luke
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: