# HG changeset patch # User Judd Storrs # Date 1293007786 18000 # Node ID b8b08b1ac21f84e83c281a24fb898d9eefa53bcd # Parent a9a3ee461b8336f59bc13076c52029c46e4799be Add missing operator functions to doc/interpreter. diff --git a/doc/ChangeLog b/doc/ChangeLog --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,11 @@ +2010-12-22 Judd Storrs + + * interpreter/expr.txi: Insert operator function docstrings. + * interpreter/oop.txi: Remove conflicting anchors for operator + functions. Add cindex entries for overloaded operators. Add + overloads to opindex. + * interpreter/numbers.txi: Fix colon opindex. + 2010-12-19 Rik * interpreter/func.txi, interpreter/sparse.txi: Remove documentation diff --git a/doc/interpreter/expr.txi b/doc/interpreter/expr.txi --- a/doc/interpreter/expr.txi +++ b/doc/interpreter/expr.txi @@ -48,6 +48,7 @@ @opindex ( @opindex ) +@opindex : An @dfn{index expression} allows you to reference or extract selected elements of a matrix or vector. @@ -560,6 +561,50 @@ preferring the longest possible match at any given point, it is more useful in this case. +@opindex ' +@DOCSTRING(ctranspose) + +@opindex .\ +@DOCSTRING(ldivide) + +@opindex - +@DOCSTRING(minus) + +@opindex \ +@DOCSTRING(mldivide) + +@opindex ** +@opindex ^ +@DOCSTRING(mpower) + +@opindex / +@DOCSTRING(mrdivide) + +@opindex * +@DOCSTRING(mtimes) + +@opindex + +@DOCSTRING(plus) + +@opindex .** +@opindex .^ +@DOCSTRING(power) + +@opindex ./ +@DOCSTRING(rdivide) + +@opindex .* +@DOCSTRING(times) + +@opindex .' +@DOCSTRING(transpose) + +@opindex - +@DOCSTRING(uminus) + +@opindex + +@DOCSTRING(uplus) + @node Comparison Ops @section Comparison Operators @cindex comparison expressions @@ -639,10 +684,29 @@ function, not with the comparison operators listed above. @xref{Strings}. +@opindex == +@DOCSTRING(eq) + +@opindex >= +@DOCSTRING(ge) + +@opindex > +@DOCSTRING(gt) + @DOCSTRING(isequal) @DOCSTRING(isequalwithequalnans) +@opindex <= +@DOCSTRING(le) + +@opindex < +@DOCSTRING(lt) + +@opindex != +@opindex ~= +@DOCSTRING(ne) + @node Boolean Expressions @section Boolean Expressions @cindex expressions, boolean @@ -737,6 +801,16 @@ This behavior is necessary for the boolean operators to work as described for matrix-valued operands. +@opindex & +@DOCSTRING(and) + +@opindex ~ +@opindex ! +@DOCSTRING(not) + +@opindex | +@DOCSTRING(or) + @node Short-circuit Boolean Operators @subsection Short-circuit Boolean Operators @cindex short-circuit evaluation diff --git a/doc/interpreter/numbers.txi b/doc/interpreter/numbers.txi --- a/doc/interpreter/numbers.txi +++ b/doc/interpreter/numbers.txi @@ -363,7 +363,7 @@ @cindex range expressions @cindex expression, range -@opindex colon +@opindex : A @dfn{range} is a convenient way to write a row vector with evenly spaced elements. A range expression is defined by the value of the first diff --git a/doc/interpreter/oop.txi b/doc/interpreter/oop.txi --- a/doc/interpreter/oop.txi +++ b/doc/interpreter/oop.txi @@ -460,15 +460,67 @@ @node Operator Overloading @subsection Operator Overloading +@cindex addition +@cindex and operator +@cindex arithmetic operators +@cindex boolean expressions +@cindex boolean operators +@cindex comparison expressions +@cindex complex-conjugate transpose +@cindex division +@cindex equality operator +@cindex equality, tests for +@cindex exponentiation +@cindex expressions, boolean +@cindex expressions, comparison +@cindex expressions, logical +@cindex greater than operator +@cindex Hermitian operator +@cindex less than operator +@cindex logical expressions +@cindex logical operators +@cindex matrix multiplication +@cindex multiplication +@cindex negation +@cindex not operator +@cindex operators, arithmetic +@cindex operators, boolean +@cindex operators, logical +@cindex operators, relational +@cindex or operator +@cindex quotient +@cindex relational operators +@cindex subtraction +@cindex tests for equality +@cindex transpose +@cindex transpose, complex-conjugate +@cindex unary minus @float Table,tab:overload_ops - -@anchor{doc-rdivide} @anchor{doc-plus} @anchor{doc-minus} @anchor{doc-uminus} -@anchor{doc-uplus} @anchor{doc-times} @anchor{doc-mtimes} @anchor{doc-mrdivide} -@anchor{doc-ldivide} @anchor{doc-mldivide} @anchor{doc-power} -@anchor{doc-mpower} @anchor{doc-lt} @anchor{doc-le} @anchor{doc-gt} -@anchor{doc-ge} @anchor{doc-eq} @anchor{doc-ne} @anchor{doc-and} -@anchor{doc-or} @anchor{doc-not} @anchor{doc-ctranspose} @anchor{doc-transpose} +@opindex + +@opindex - +@opindex .* +@opindex * +@opindex ./ +@opindex / +@opindex .\ +@opindex \ +@opindex .^ +@opindex ^ +@opindex < +@opindex <= +@opindex > +@opindex >= +@opindex == +@opindex != +@opindex ~= +@opindex & +@opindex | +@opindex ! +@opindex ' +@opindex .' +@opindex : +@opindex < @tex \vskip 6pt