function data = getAutoCompleteFunctionsList(blk)
%

%   Copyright 2016-2020 The MathWorks, Inc.

functions = Simulink.FunctionGraphCatalog(blk);
idx = 1;
data = {};
for row = 1:length(functions)
    if ~isempty(functions(row).handle)
        fcnPrototype = {functions(row).prototypes};
        if (~isempty(fcnPrototype{1}))
            for pIdx = 1:length(fcnPrototype)
                data{idx,1} = fcnPrototype{pIdx,:};
                idx = idx + 1;
            end
        end
    end
end
data = unique(data);
if isempty(data)
    % if there are no functions in the model, add a space so that defaults
    % such as units do not get pulled in to form the list
    data = {' '};
end
end
