This function creates a fork, sets the variable named targetValue in the targetEnvironment to NULL, evaluates a segment of code evaluated in the fork, and the result of the fork returned in a variable named targetValue in the targetEnvironment after the next top-level command completes. If there is an error in the code, the returned variable will be a try-error. These effects are accomplished via the automatic creation and destruction of a taskCallback and other functions inside the mcparallelDoManager. If job results have to be collected before you return to the top level, use mcparallelDoCheck.
Creates a callback handler function that can be added via addTaskCallback(). These functions run at the end of each completed R statement. This particular handler watches for the completion of the target job, which is created via mcparallel()