Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change canvasInRendering to a WeakSet instead of a WeakMap #10203

Merged

Conversation

Snuffleupagus
Copy link
Collaborator

Note how nowhere in the code canvasInRendering.get() is ever called, and that this structure is really only used to store references to <canvas> DOM elements.
The reason for this being a WeakMap is probably because at the time we weren't using core-js polyfills yet, and since there already existed a manually implemented WeakMap polyfill it was probably simpler to use that.

Note how nowhere in the code `canvasInRendering.get()` is ever called, and that this structure is really only used to store references to `<canvas>` DOM elements.
The reason for this being a `WeakMap` is probably because at the time we weren't using `core-js` polyfills yet, and since there already existed a manually implemented `WeakMap` polyfill it was probably simpler to use that.
@timvandermeij
Copy link
Contributor

/botio test

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Received

Command cmd_test from @timvandermeij received. Current queue size: 0

Live output at: http://54.67.70.0:8877/baaa32dd4816465/output.txt

@pdfjsbot
Copy link

From: Bot.io (Windows)


Received

Command cmd_test from @timvandermeij received. Current queue size: 1

Live output at: http://54.215.176.217:8877/39730b17a4408ca/output.txt

@pdfjsbot
Copy link

From: Bot.io (Linux m4)


Success

Full output at http://54.67.70.0:8877/baaa32dd4816465/output.txt

Total script time: 19.15 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@pdfjsbot
Copy link

From: Bot.io (Windows)


Success

Full output at http://54.215.176.217:8877/39730b17a4408ca/output.txt

Total script time: 24.74 mins

  • Font tests: Passed
  • Unit tests: Passed
  • Regression tests: Passed

@timvandermeij timvandermeij merged commit 7053b5a into mozilla:master Oct 31, 2018
@timvandermeij
Copy link
Contributor

Looks like a better choice to me too. Thanks!

@Snuffleupagus Snuffleupagus deleted the canvasInRendering-WeakSet branch October 31, 2018 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants