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

[css-typed-om] Ensure serialization of deeply nested math operators d… #33756

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

achristensen07
Copy link
Contributor

…oes not crash

This comes from a WebKit fix in https://bugs.webkit.org/show_bug.cgi?id=239562

@tabatkins
Copy link
Contributor

I'd be fine with approving this, but in general we do allow for OOMs and such to just happen, so long as they're for reasonably excessive cases. I think a 100k-deep stack of OM classes is such a case; you're looking at a serialization around 1MB in size. ^_^

Correctly serializing arbitrarily-deep trees is cool, but I do wonder if a smaller limit might capture reasonable use-cases sufficiently well while still allowing more limited impls to work. If an impl relies on recursion, I guess handling a stack of 1k depth might be about the limit one can reasonably expect? Python's stack depth is 1k, at least.

@achristensen07
Copy link
Contributor Author

I didn't verify the output of the serialization, so an implementation could make a maximum stack depth or use a non-recursive algorithm and still pass.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants