async_hooks: docs and api ergonomics tweaks
Some doc improvements and a AsyncResource constructor ergonomics tweak...
Previously, if type
was passed to the AsyncResource
class as null
or undefined
,
an error would be thrown. With this, type
defaults to new.target.name
.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines
Affected core subsystem(s)
async_hooks