User`s guide

B Error and Warning Messages
B-6
Error: File:
filename
Line: # Column: # Missing variable or function. An illeg al name was
used for a variable or function. For example,
x % Correct
_x % Incorrect
Error: File:
filename
Line: # Column: # Only functions can return multiple values. In this
exampl e ,
foo must be a function, it cannot be a variable.
[a, b] = foo;
Error: File:
filename
Line: # Column: # "
string1
" expected, "
string2
" found. There is a
syntax error in the specified line. See the online MATLAB Function Reference
pages accessible from the online Help.
Error: File:
filename
Line: # Column: # The end operator can only be used within an array
index expression.
Youcanusetheendoperatorinanarrayindexexpressionsuch
as
sum(A(:, end)). You cannot use the end operator outside of such an
expression, for example,
y = 1 + end.
Error: File:
filename
Line: # Column: # The name "
parametername
" occurs twice as an input
parameter.
The vari abl e na mes specified on t he function declara tion line must
be unique. For example,
function foo(bar1, bar2) % Correct
function foo(bar, bar) % Incorrect
Error: File:
filename
Line: # Column: # The name "
parametername
" occurs twice as an output
parameter.
The variable names specified on the function declaration line must
be unique. For example,
function [bar1, bar2] = foo % Correct
function [bar, bar] = foo % Incorrect
Error: File:
filename
Line: # Column: # The '
operatorname
' operator may only produce a single
output.
The primitive operator produces only a single output. For example,
x = 1:10; % is correct
[x, y] = 1:10; % is incorrect
Error: File:
filename
Line: # Column: # The PERSISTENT declaration must precede any use of
the variable
variablename
. In the text of the function, there is a reference to the
variable before the persistent declaration.