Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upStore Option<ImageInfo> instead of making fields of ImageInfo optional #24582
Comments
|
Hi! If you have any questions regarding this issue, feel free to make a comment here, or ask it in the If you intend to work on this issue, then add |
|
@highfive assign me |
|
Hey @teapotd! Thanks for your interest in working on this issue. It's now assigned to you! |
bors-servo
added a commit
that referenced
this issue
Oct 31, 2019
bors-servo
added a commit
that referenced
this issue
Nov 1, 2019
bors-servo
added a commit
that referenced
this issue
Nov 1, 2019
bors-servo
added a commit
that referenced
this issue
Nov 1, 2019
bors-servo
added a commit
that referenced
this issue
Nov 1, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The code in WebGLTexture stores an array of ImageInfo objects. Each of these objects has a
is_initializedfield, and other fields that are given default values. This makes the code harder to reason about; it would be easier to read if the array containedOption<ImageInfo>instead and any checks for initialization checked foris_none()oris_some()instead.Code:
components/script/dom/webgltexture.rsTests:
./mach test-wpt tests/wpt/webgl/tests/conformance/textures(there should be no difference before and after)