function varargout = pGatherAndCall(fcn, varargin)
; %#ok<NOSEM> % Undocumented
%pGatherAndCall Hidden static method to gather all codistributed arguments 
%   and call the specified function.
%   


%   Copyright 2020 The MathWorks, Inc.

% Gather all codistributed inputs and call the specified function.
varargin = distributedutil.CodistParser.gatherElements(varargin);
varargout = cell(1,max(1,nargout));
[varargout{:}] = feval(fcn, varargin{:});
