W3cubDocs

/Octave

F.1 Keywords

The following identifiers are keywords, and may not be used as variable or function names:

__FILE__ __LINE__ break
case catch classdef
continue do else
elseif end end_try_catch
end_unwind_protect endclassdef endenumeration
endevents endfor endfunction
endif endmethods endparfor
endproperties endswitch endwhile
enumeration events for
function global if
methods otherwise parfor
persistent properties return
switch try until
unwind_protect unwind_protect_cleanup while

The function iskeyword can be used to quickly check whether an identifier is reserved by Octave.

iskeyword ()
iskeyword (name)

Return true if name is an Octave keyword.

If name is omitted, return a list of keywords.

See also: isvarname, exist.

© 1996–2018 John W. Eaton
Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies.
Permission is granted to copy and distribute modified versions of this manual under the conditions for verbatim copying, provided that the entire resulting derived work is distributed under the terms of a permission notice identical to this one.Permission is granted to copy and distribute translations of this manual into another language, under the above conditions for modified versions.
https://octave.org/doc/interpreter/Keywords.html