Mercurial > octave
annotate scripts/miscellaneous/warning_ids.m @ 14116:951eacaf9381 stable
Initial documentation for broadcasting and general vectorization guidelines
* vectorize.txi: New file.
* NEWS: Update with location of broadcasting documentation.
* Makefile.am: Add vectorize.texi
* arith.txi: Move accumarray and accumdim docstring to vectorize.txi
* container.txi: Move structfun docstring to vectorize.txi
* expr.txi: Mention broadcasting where relevant.
* func.txi: Move vectorize docstring to vectorize.txi
* matrix.txi: Move function application section to vectorize.txi
* octave.texi: Add vectorize.txi and its menu options
* sparse.txi: Move spfun to vectorize.txi
* tips.txi: Move and rewrite coding tips section in vectorize.txi
* bsxfun.h (is_valid_bsxfun, is_valid_inplace_bsxfun): Rename warning
to "Octave:broadcast"
* accumdim.m: Reformat to use @example in lieu of @smallexample
* warning_ids.m: Add Octave:broadcast
* bsxfun.cc: Reword docstring to mention broadcasting
* cellfun.cc: Move comment about efficiency from tips.txi
* version.h.in: Add a big startup warning about broadcasting
author | Jordi Gutiérrez Hermoso <jordigh@octave.org> |
---|---|
date | Tue, 27 Dec 2011 15:15:41 -0500 |
parents | 4aadd3e2c5bc |
children | 94e2a76f1e5a |
rev | line source |
---|---|
11523 | 1 ## Copyright (C) 2006-2011 John W. Eaton |
7016 | 2 ## |
3 ## This file is part of Octave. | |
4 ## | |
5 ## Octave is free software; you can redistribute it and/or modify it | |
6 ## under the terms of the GNU General Public License as published by | |
7 ## the Free Software Foundation; either version 3 of the License, or (at | |
8 ## your option) any later version. | |
9 ## | |
10 ## Octave is distributed in the hope that it will be useful, but | |
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 ## General Public License for more details. | |
14 ## | |
15 ## You should have received a copy of the GNU General Public License | |
16 ## along with Octave; see the file COPYING. If not, see | |
17 ## <http://www.gnu.org/licenses/>. | |
18 | |
5781 | 19 ## -*- texinfo -*- |
20 ## @table @code | |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
21 ## @item Octave:abbreviated-property-match |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
22 ## By default, the @code{Octave:abbreviated-property-match} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
23 ## |
5781 | 24 ## @item Octave:array-to-scalar |
25 ## If the @code{Octave:array-to-scalar} warning is enabled, Octave will | |
26 ## warn when an implicit conversion from an array to a scalar value is | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
27 ## attempted. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
28 ## By default, the @code{Octave:array-to-scalar} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
29 ## |
5781 | 30 ## @item Octave:array-to-vector |
31 ## If the @code{Octave:array-to-vector} warning is enabled, Octave will | |
32 ## warn when an implicit conversion from an array to a vector value is | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
33 ## attempted. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
34 ## By default, the @code{Octave:array-to-vector} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
35 ## |
5781 | 36 ## @item Octave:assign-as-truth-value |
37 ## If the @code{Octave:assign-as-truth-value} warning is | |
38 ## enabled, a warning is issued for statements like | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
39 ## |
5781 | 40 ## @example |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
41 ## @group |
5781 | 42 ## if (s = t) |
9039
51dc9691f23f
Cleanup documentation files errors.texi, debug.texi, io.texi
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
43 ## @dots{} |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
44 ## @end group |
5781 | 45 ## @end example |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
46 ## |
5781 | 47 ## @noindent |
48 ## since such statements are not common, and it is likely that the intent | |
49 ## was to write | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
50 ## |
5781 | 51 ## @example |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
52 ## @group |
5781 | 53 ## if (s == t) |
9039
51dc9691f23f
Cleanup documentation files errors.texi, debug.texi, io.texi
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
54 ## @dots{} |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
55 ## @end group |
5781 | 56 ## @end example |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
57 ## |
5781 | 58 ## @noindent |
59 ## instead. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
60 ## |
5781 | 61 ## There are times when it is useful to write code that contains |
62 ## assignments within the condition of a @code{while} or @code{if} | |
63 ## statement. For example, statements like | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
64 ## |
5781 | 65 ## @example |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
66 ## @group |
5781 | 67 ## while (c = getc()) |
9039
51dc9691f23f
Cleanup documentation files errors.texi, debug.texi, io.texi
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
68 ## @dots{} |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
69 ## @end group |
5781 | 70 ## @end example |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
71 ## |
5781 | 72 ## @noindent |
73 ## are common in C programming. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
74 ## |
5781 | 75 ## It is possible to avoid all warnings about such statements by |
76 ## disabling the @code{Octave:assign-as-truth-value} warning, | |
77 ## but that may also let real errors like | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
78 ## |
5781 | 79 ## @example |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
80 ## @group |
5781 | 81 ## if (x = 1) # intended to test (x == 1)! |
9039
51dc9691f23f
Cleanup documentation files errors.texi, debug.texi, io.texi
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
82 ## @dots{} |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
83 ## @end group |
5781 | 84 ## @end example |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
85 ## |
5781 | 86 ## @noindent |
87 ## slip by. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
88 ## |
5781 | 89 ## In such cases, it is possible suppress errors for specific statements by |
90 ## writing them with an extra set of parentheses. For example, writing the | |
91 ## previous example as | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
92 ## |
5781 | 93 ## @example |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
94 ## @group |
5781 | 95 ## while ((c = getc())) |
9039
51dc9691f23f
Cleanup documentation files errors.texi, debug.texi, io.texi
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
96 ## @dots{} |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
97 ## @end group |
5781 | 98 ## @end example |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
99 ## |
5781 | 100 ## @noindent |
101 ## will prevent the warning from being printed for this statement, while | |
102 ## allowing Octave to warn about other assignments used in conditional | |
103 ## contexts. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
104 ## |
5781 | 105 ## By default, the @code{Octave:assign-as-truth-value} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
106 ## |
5781 | 107 ## @item Octave:associativity-change |
108 ## If the @code{Octave:associativity-change} warning is | |
109 ## enabled, Octave will warn about possible changes in the meaning of | |
110 ## some code due to changes in associativity for some operators. | |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
111 ## Associativity changes have typically been made for @sc{matlab} |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
112 ## compatibility. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
113 ## By default, the @code{Octave:associativity-change} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
114 ## |
12486
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
115 ## @item Octave:autoload-relative-file-name |
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
116 ## If the @code{Octave:autoload-relative-file-name} is enabled, |
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
117 ## Octave will warn when parsing autoload() function calls with relative |
12575
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
118 ## paths to function files. This usually happens when using autoload() |
12486
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
119 ## calls in PKG_ADD files, when the PKG_ADD file is not in the same |
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
120 ## directory as the .oct file referred to by the autoload() command. |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
121 ## By default, the @code{Octave:autoload-relative-file-name} warning is enabled. |
12486
32279948bf3b
Document the Octave:autoload-relative-file-name warning.
Thomas Weber <tweber@debian.org>
parents:
12477
diff
changeset
|
122 ## |
14116
951eacaf9381
Initial documentation for broadcasting and general vectorization guidelines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
13842
diff
changeset
|
123 ## @item Octave:broadcast |
951eacaf9381
Initial documentation for broadcasting and general vectorization guidelines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
13842
diff
changeset
|
124 ## Warn when performing broadcasting operations. By default, this is |
951eacaf9381
Initial documentation for broadcasting and general vectorization guidelines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
13842
diff
changeset
|
125 ## enabled. See the Broadcasting section in the Vectorization and Faster |
951eacaf9381
Initial documentation for broadcasting and general vectorization guidelines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
13842
diff
changeset
|
126 ## Code Execution chapter in the manual. |
951eacaf9381
Initial documentation for broadcasting and general vectorization guidelines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
13842
diff
changeset
|
127 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
128 ## @item Octave:built-in-variable-assignment |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
129 ## By default, the @code{Octave:built-in-variable-assignment} warning is |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
130 ## enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
131 ## |
5781 | 132 ## @item Octave:divide-by-zero |
133 ## If the @code{Octave:divide-by-zero} warning is enabled, a | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
134 ## warning is issued when Octave encounters a division by zero. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
135 ## By default, the @code{Octave:divide-by-zero} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
136 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
137 ## @item Octave:fopen-file-in-path |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
138 ## By default, the @code{Octave:fopen-file-in-path} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
139 ## |
5781 | 140 ## @item Octave:function-name-clash |
141 ## If the @code{Octave:function-name-clash} warning is enabled, a | |
142 ## warning is issued when Octave finds that the name of a function | |
143 ## defined in a function file differs from the name of the file. (If | |
144 ## the names disagree, the name declared inside the file is ignored.) | |
145 ## By default, the @code{Octave:function-name-clash} warning is enabled. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
146 ## |
5781 | 147 ## @item Octave:future-time-stamp |
148 ## If the @code{Octave:future-time-stamp} warning is enabled, Octave | |
149 ## will print a warning if it finds a function file with a time stamp | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
150 ## that is in the future. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
151 ## By default, the @code{Octave:future-time-stamp} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
152 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
153 ## @item Octave:glyph-render |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
154 ## By default, the @code{Octave:glyph-render} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
155 ## |
5781 | 156 ## @item Octave:imag-to-real |
157 ## If the @code{Octave:imag-to-real} warning is enabled, a warning is | |
158 ## printed for implicit conversions of complex numbers to real numbers. | |
159 ## By default, the @code{Octave:imag-to-real} warning is disabled. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
160 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
161 ## @item Octave:load-file-in-path |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
162 ## By default, the @code{Octave:load-file-in-path} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
163 ## |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
164 ## @item Octave:logical-conversion |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
165 ## By default, the @code{Octave:logical-conversion} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
166 ## |
5794 | 167 ## @item Octave:matlab-incompatible |
168 ## Print warnings for Octave language features that may cause | |
9051
1bf0ce0930be
Grammar check TexInfo in all .m files
Rik <rdrider0-list@yahoo.com>
parents:
9039
diff
changeset
|
169 ## compatibility problems with @sc{matlab}. |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
170 ## By default, the @code{Octave:matlab-incompatible} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
171 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
172 ## @item Octave:md5sum-file-in-path |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
173 ## By default, the @code{Octave:md5sum-file-in-path} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
174 ## |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
175 ## @item Octave:missing-glyph |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
176 ## By default, the @code{Octave:missing-glyph} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
177 ## |
5781 | 178 ## @item Octave:missing-semicolon |
179 ## If the @code{Octave:missing-semicolon} warning is enabled, Octave | |
180 ## will warn when statements in function definitions don't end in | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
181 ## semicolons. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
182 ## By default the @code{Octave:missing-semicolon} warning is disabled. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
183 ## |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
184 ## @item Octave:mixed-string-concat |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
185 ## If the @code{Octave:mixed-string-concat} warning is enabled, print a |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
186 ## warning when concatenating a mixture of double and single quoted strings. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
187 ## By default, the @code{Octave:mixed-string-concat} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
188 ## |
5781 | 189 ## @item Octave:neg-dim-as-zero |
190 ## If the @code{Octave:neg-dim-as-zero} warning is enabled, print a warning | |
191 ## for expressions like | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
192 ## |
5781 | 193 ## @example |
194 ## eye (-1) | |
195 ## @end example | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
196 ## |
5781 | 197 ## @noindent |
198 ## By default, the @code{Octave:neg-dim-as-zero} warning is disabled. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
199 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
200 ## @item Octave:nested-functions-coerced |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
201 ## By default, the @code{Octave:nested-functions-coerced} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
202 ## |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
203 ## @item Octave:noninteger-range-as-index |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
204 ## By default, the @code{Octave:noninteger-range-as-index} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
205 ## |
5781 | 206 ## @item Octave:num-to-str |
207 ## If the @code{Octave:num-to-str} warning is enable, a warning is | |
208 ## printed for implicit conversions of numbers to their ASCII character | |
209 ## equivalents when strings are constructed using a mixture of strings and | |
210 ## numbers in matrix notation. For example, | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
211 ## |
5781 | 212 ## @example |
213 ## @group | |
214 ## [ "f", 111, 111 ] | |
215 ## @result{} "foo" | |
216 ## @end group | |
217 ## @end example | |
10821
693e22af08ae
Grammarcheck documentation of m-files
Rik <octave@nomad.inbox5.com>
parents:
9051
diff
changeset
|
218 ## |
10846
a4f482e66b65
Grammarcheck more of the documentation.
Rik <octave@nomad.inbox5.com>
parents:
10821
diff
changeset
|
219 ## @noindent |
5781 | 220 ## elicits a warning if the @code{Octave:num-to-str} warning is |
221 ## enabled. By default, the @code{Octave:num-to-str} warning is enabled. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
222 ## |
12477
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
223 ## @item Octave:possible-matlab-short-circuit-operator |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
224 ## If the @code{Octave:possible-matlab-short-circuit-operator} warning |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
225 ## is enabled, Octave will warn about using the not short circuiting |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
226 ## operators @code{&} and @code{|} inside @code{if} or @code{while} |
12575
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
227 ## conditions. They normally never short circuit, but @sc{matlab} always |
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
228 ## short circuits if any logical operators are used in a condition. You |
12477
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
229 ## can turn on the option |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
230 ## |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
231 ## @example |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
232 ## @group |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
233 ## do_braindead_shortcircuit_evaluation(1) |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
234 ## @end group |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
235 ## @end example |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
236 ## |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
237 ## @noindent |
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
238 ## if you would like to enable this short-circuit evaluation in |
12575
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
239 ## Octave. Note that the @code{&&} and @code{||} operators always short |
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
240 ## circuit in both Octave and @sc{matlab}, so it's only necessary to |
d0b799dafede
Grammarcheck files for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12486
diff
changeset
|
241 ## enable @sc{matlab}-style short-circuiting it's too arduous to modify |
12576
a1e386b9ef4b
Spellcheck documentation for 3.4.1 release.
Rik <octave@nomad.inbox5.com>
parents:
12575
diff
changeset
|
242 ## existing code that relies on this behavior. |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
243 ## By default, the @code{Octave:possible-matlab-short-circuit-operator} warning |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
244 ## is enabled. |
12477
d1466d956d17
Add a warning description for Matlab-style short-circuiting
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
11587
diff
changeset
|
245 ## |
5781 | 246 ## @item Octave:precedence-change |
247 ## If the @code{Octave:precedence-change} warning is enabled, Octave | |
248 ## will warn about possible changes in the meaning of some code due to | |
249 ## changes in precedence for some operators. Precedence changes have | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
250 ## typically been made for @sc{matlab} compatibility. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
251 ## By default, the @code{Octave:precedence-change} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
252 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
253 ## @item Octave:recursive-path-search |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
254 ## By default, the @code{Octave:recursive-path-search} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
255 ## |
5781 | 256 ## @item Octave:reload-forces-clear |
257 ## If several functions have been loaded from the same file, Octave must | |
258 ## clear all the functions before any one of them can be reloaded. If | |
259 ## the @code{Octave:reload-forces-clear} warning is enabled, Octave will | |
260 ## warn you when this happens, and print a list of the additional | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
261 ## functions that it is forced to clear. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
262 ## By default, the @code{Octave:reload-forces-clear} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
263 ## |
5781 | 264 ## @item Octave:resize-on-range-error |
265 ## If the @code{Octave:resize-on-range-error} warning is enabled, print a | |
266 ## warning when a matrix is resized by an indexed assignment with | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
267 ## indices outside the current bounds. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
268 ## By default, the ## @code{Octave:resize-on-range-error} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
269 ## |
5794 | 270 ## @item Octave:separator-insert |
271 ## Print warning if commas or semicolons might be inserted | |
272 ## automatically in literal matrices. | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
273 ## By default, the @code{Octave:separator-insert} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
274 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
275 ## @item Octave:shadowed-function |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
276 ## By default, the @code{Octave:shadowed-function} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
277 ## |
5794 | 278 ## @item Octave:single-quote-string |
8325
b93ac0586e4b
spelling corrections
Brian Gough<bjg@network-theory.co.uk>
parents:
7017
diff
changeset
|
279 ## Print warning if a single quote character is used to introduce a |
5794 | 280 ## string constant. |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
281 ## By default, the @code{Octave:single-quote-string} warning is disabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
282 ## |
13842
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
283 ## @item Octave:singular-matrix-div |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
284 ## By default, the @code{Octave:singular-matrix-div} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
285 ## |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
286 ## @item Octave:sqrtm:SingularMatrix |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
287 ## By default, the @code{Octave:sqrtm:SingularMatrix} warning is enabled. |
4aadd3e2c5bc
warning_ids.m: Add missing warnings to list. They are not documented.
Rik <octave@nomad.inbox5.com>
parents:
13841
diff
changeset
|
288 ## |
5781 | 289 ## @item Octave:str-to-num |
290 ## If the @code{Octave:str-to-num} warning is enabled, a warning is printed | |
291 ## for implicit conversions of strings to their numeric ASCII equivalents. | |
292 ## For example, | |
10821
693e22af08ae
Grammarcheck documentation of m-files
Rik <octave@nomad.inbox5.com>
parents:
9051
diff
changeset
|
293 ## |
5781 | 294 ## @example |
295 ## @group | |
296 ## "abc" + 0 | |
297 ## @result{} 97 98 99 | |
298 ## @end group | |
299 ## @end example | |
10821
693e22af08ae
Grammarcheck documentation of m-files
Rik <octave@nomad.inbox5.com>
parents:
9051
diff
changeset
|
300 ## |
10846
a4f482e66b65
Grammarcheck more of the documentation.
Rik <octave@nomad.inbox5.com>
parents:
10821
diff
changeset
|
301 ## @noindent |
5781 | 302 ## elicits a warning if the @code{Octave:str-to-num} warning is enabled. |
303 ## By default, the @code{Octave:str-to-num} warning is disabled. | |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
304 ## |
5781 | 305 ## @item Octave:undefined-return-values |
306 ## If the @code{Octave:undefined-return-values} warning is disabled, | |
307 ## print a warning if a function does not define all the values in | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
308 ## the return list which are expected. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
309 ## By default, the @code{Octave:undefined-return-values} warning is enabled. |
11587
c792872f8942
all script files: untabify and strip trailing whitespace
John W. Eaton <jwe@octave.org>
parents:
11523
diff
changeset
|
310 ## |
5781 | 311 ## @item Octave:variable-switch-label |
312 ## If the @code{Octave:variable-switch-label} warning is enabled, Octave | |
313 ## will print a warning if a switch label is not a constant or constant | |
13841
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
314 ## expression. |
0a158dbdb04a
Remove 3 unused warning ids
Rik <octave@nomad.inbox5.com>
parents:
12845
diff
changeset
|
315 ## By default, the @code{Octave:variable-switch-label} warning is disabled. |
5781 | 316 ## @end table |
8673
9e0f0a7bf858
warning_ids.m: make it a function that just calls help
John W. Eaton <jwe@octave.org>
parents:
8325
diff
changeset
|
317 |
9e0f0a7bf858
warning_ids.m: make it a function that just calls help
John W. Eaton <jwe@octave.org>
parents:
8325
diff
changeset
|
318 function warning_ids () |
9e0f0a7bf858
warning_ids.m: make it a function that just calls help
John W. Eaton <jwe@octave.org>
parents:
8325
diff
changeset
|
319 help ("warning_ids"); |
9e0f0a7bf858
warning_ids.m: make it a function that just calls help
John W. Eaton <jwe@octave.org>
parents:
8325
diff
changeset
|
320 endfunction |
12845
29d4b27e485d
Remove warning_ids.m from test statistics.
Rik <octave@nomad.inbox5.com>
parents:
12576
diff
changeset
|
321 |
29d4b27e485d
Remove warning_ids.m from test statistics.
Rik <octave@nomad.inbox5.com>
parents:
12576
diff
changeset
|
322 ## Remove from test statistics. No real tests possible |
29d4b27e485d
Remove warning_ids.m from test statistics.
Rik <octave@nomad.inbox5.com>
parents:
12576
diff
changeset
|
323 %!assert (1) |