Why does tab completion not work for p-coded function arguments in MATLAB R2020b?
Show older comments
I am using an "arguments" block to define name-value arguments for a MATLAB function, "myRectangle":
function myRectangle(X,Y,options)
arguments
X double
Y double
options.LineStyle (1,1) string = "-"
options.LineWidth (1,1) {mustBeNumeric} = 1
end
% Function code
...
end
I got "myRectangle" from the "arguments" documentation page:
https://www.mathworks.com/help/releases/R2020b/matlab/ref/arguments.html#mw_c78db305-0136-4d4c-b880-f6615c757d8d
I can use tab completion to complete name-value arguments of "myRectangle" when the function is an M-file:

Alt text: The MATLAB command window while I am calling "myRectangle". The tab complete menu shows "LineStyle" and "LineWidth".
However, when "myRectangle" is a P file, MATLAB finds no completions:

Alt text: The MATLAB command window. The command window shows that "myRectangle" is p-coded, and the tab completion menu shows "No completions found."
How can I modify my P file so that I can use tab completion on its arguments?
Accepted Answer
More Answers (0)
Categories
Find more on Programming in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!