function r = parfevalOnAll(aPool, varargin)
%

% Copyright 2013-2021 The MathWorks, Inc.

if ~isscalar(aPool)
    r = parfevalOnAll@parallel.Pool(aPool, varargin{:});
    return;
end
parfevalErrorCheckPool(aPool, 'parfevalOnAll');
try
    r = parfevalOnAll(aPool.FevalQueue, varargin{:});
catch E
    throw(E);
end
end
