Mercurial > octave
diff libinterp/corefcn/sparse-xpow.cc @ 17749:ef7e97c91006
Adding elementwise hint to the power errors.
author | Serhiy Zahoriya <xintx.ua@gmail.com> |
---|---|
date | Thu, 24 Oct 2013 04:32:11 +0300 |
parents | d63878346099 |
children | 175b392e91fe |
line wrap: on
line diff
--- a/libinterp/corefcn/sparse-xpow.cc Thu Oct 24 12:38:24 2013 +0200 +++ b/libinterp/corefcn/sparse-xpow.cc Thu Oct 24 04:32:11 2013 +0300 @@ -64,7 +64,7 @@ octave_idx_type nc = a.cols (); if (nr == 0 || nc == 0 || nr != nc) - error ("for A^b, A must be a square matrix"); + error ("for A^b, A must be a square matrix. Use .^ for elementwise power."); else { if (static_cast<int> (b) == b) @@ -137,7 +137,7 @@ octave_idx_type nc = a.cols (); if (nr == 0 || nc == 0 || nr != nc) - error ("for A^b, A must be a square matrix"); + error ("for A^b, A must be a square matrix. Use .^ for elementwise power."); else { if (static_cast<int> (b) == b)