Next: , Up: Grammar and Parser


I.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 endevents
endfor endfunction endif
endmethods endproperties endswitch
endwhile events for
function get global
if methods otherwise
persistent properties return
set static switch
try until unwind_protect
unwind_protect_cleanupwhile

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

— Built-in Function: iskeyword ()
— Built-in Function: iskeyword (name)

Return true if name is an Octave keyword. If name is omitted, return a list of keywords.

See also: isvarname, exist.