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

Add CollectGarbage and RuntimeObject to wsh #156

Merged
merged 2 commits into from
Nov 19, 2019

Conversation

kevinoid
Copy link
Contributor

This PR adds two additional global functions provided by JScript in Windows Script Host and specified by Microsoft:

I can confirm both variables are present on both Windows 7 and 10.

Thanks,
Kevin

[CollectGarbage] is a function provided by JScript on the global object
which triggers the garbage collector.  It is required to [work around
ActiveX object retention issues] in some situations.

[CollectGarbage]: https://docs.microsoft.com/en-us/openspecs/ie_standards/ms-es3ex/73a13f4c-72b3-48f3-b2f4-933084ec8716
[work around ActiveX object retention issues]: https://docs.microsoft.com/en-us/office/troubleshoot/excel/jscript-not-shut-down-excel

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
[RuntimeObject] is a function provided by JScript on the global object
for enumerating functions and variables defined in the global scope.

[RuntimeObject]: https://docs.microsoft.com/en-us/openspecs/ie_standards/ms-es3ex/a17cdcdb-ef33-43e0-b269-9634e59b1a00

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
@sindresorhus sindresorhus merged commit 21467a7 into sindresorhus:master Nov 19, 2019
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.

2 participants