Next: Coding Tips, Up: Tips
Here are some tips for avoiding common errors in writing Octave code intended for widespread use:
If you write a function that you think ought to be added to Octave under
a certain name, such as fiddle_matrix
, don't call it by that name
in your program. Call it mylib_fiddle_matrix
in your program,
and send mail to [email protected] suggesting that it
be added to Octave. If and when it is, the name can be changed easily
enough.
If one prefix is insufficient, your package may use two or three alternative common prefixes, so long as they make sense.
Separate the prefix from the rest of the symbol name with an underscore `_'. This will be consistent with Octave itself and with most Octave programs.
error
(or usage
). The error
and usage
functions do not
return.
See Errors.