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

feat: add sham for WeakRef #96

Merged
merged 1 commit into from
Jan 11, 2022
Merged

feat: add sham for WeakRef #96

merged 1 commit into from
Jan 11, 2022

Conversation

dsherret
Copy link
Member

@dsherret dsherret commented Jan 11, 2022

This uses the @deno/sham-weakref package, which is a "sham" for WeakRef.

It is not possible to shim WeakRef in old node environments, so this module provides a sham to allow the code to compile, but it will throw when used. The sham will use the global WeakRef if it exists though.

This also fixes a bug with type only shimming.

Closes #92

@dsherret dsherret merged commit 56c9862 into main Jan 11, 2022
@dsherret dsherret deleted the weakref_sham branch January 11, 2022 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add shim for WeakRef
1 participant