domain: forward args to .run(fn)
authormicnic <micnic90@gmail.com>
Sat, 29 Nov 2014 12:50:29 +0000 (14:50 +0200)
committerRod Vagg <rod@vagg.org>
Fri, 12 Dec 2014 01:14:11 +0000 (12:14 +1100)
commit8c69d7bed47358d5ef4a5226f60e97145300b49b
tree5ece105e77fc3367d112eb62091d521c58ecb24b
parent41ec1a7d5bdc1a467fde73a4440a7aad1fe7401c
domain: forward args to .run(fn)

Adds the feature to define arguments for the function called in
domain.run(), this is supposed to be useful when a function is called from
another context and some values from the current context are needed as
arguments, it's similar to the callback from setTimeout or setInterval.

PR-URL: https://github.com/iojs/io.js/pull/15
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
benchmark/misc/domain-fn-args.js [new file with mode: 0644]
doc/api/domain.markdown
lib/domain.js
test/simple/test-domain.js