Why do I receive an error using FEVAL when I do not have sufficient output arguments defined in the function I am calling?

4 vues (au cours des 30 derniers jours)
??? One or more output arguments not assigned during call to 'feval'.
Error in ==> D:\Applications\Matlab\6p5LCS\work\test_feval.m
On line 3 ==> [a,b,c,d] = feval('local_test',1,2,3);
In R12.1 and previous versions of MATLAB the same function would produce the following warning
Warning: One or more output arguments not assigned during call to 'feval'.
> In D:\Applications\Matlab\6p5LCS\work\test_feval.m at line 3

Réponse acceptée

MathWorks Support Team
MathWorks Support Team le 22 Jan 2010
You should define all explicit output arguments that are declared on the function declaration line. The behavior you are seeing occurs if you call any function that does not define all the variables declared in the function declaration line.
This is an intended behavior; The warning was strengthened to show errors in your user-written MATLAB code.

Plus de réponses (0)

Catégories

En savoir plus sur Performance and Memory dans Help Center et File Exchange

Produits

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by