From 00450e5454f58f8295079e6fa640ed5726f3386b Mon Sep 17 00:00:00 2001 From: Mike Miller Date: Wed, 2 Oct 2019 15:13:54 -0700 Subject: [PATCH] doc: use @error Texinfo macro for error diagnostics * errors.txi, expr.txi, external.txi, func.txi, var.txi: Use @error Texinfo macro for error diagnostics in @example blocks. * validatestring.m: Likewise. diff --git a/doc/interpreter/errors.txi b/doc/interpreter/errors.txi index 14a8f535c56b..cddfcb576373 100644 --- a/doc/interpreter/errors.txi +++ b/doc/interpreter/errors.txi @@ -118,7 +118,7 @@ error. @group f () -@print{} error: Invalid call to f. Correct usage is: +@error{} error: Invalid call to f. Correct usage is: @print{} @print{} -- f (ARG1) @print{} diff --git a/doc/interpreter/expr.txi b/doc/interpreter/expr.txi index 2c1f4ee4a5d3..64568b8a58d8 100644 --- a/doc/interpreter/expr.txi +++ b/doc/interpreter/expr.txi @@ -1345,7 +1345,7 @@ following will produce an error. @example @group [a, b, c, d] = [u, s, v] = svd (a); -@print{} error: element number 4 undefined in return list +@error{} error: element number 4 undefined in return list @end group @end example diff --git a/doc/interpreter/external.txi b/doc/interpreter/external.txi index 2b200c9fd88f..de8ca1dcf340 100644 --- a/doc/interpreter/external.txi +++ b/doc/interpreter/external.txi @@ -2054,7 +2054,7 @@ represent Java's @code{null} value and how Java exceptions are represented. @example @group javaObject ("java.math.BigDecimal", []); -@result{} error: [java] java.lang.NullPointerException +@error{} error: [java] java.lang.NullPointerException @end group @end example diff --git a/doc/interpreter/func.txi b/doc/interpreter/func.txi index 90cc9b839a3c..68f2ace3da63 100644 --- a/doc/interpreter/func.txi +++ b/doc/interpreter/func.txi @@ -1001,7 +1001,7 @@ function y = foo (to_eval) endfunction foo ("x = 5;") - @result{} error: can not add variable "x" to a static workspace + @error{} error: can not add variable "x" to a static workspace foo ("y = 10;") @result{} 10 diff --git a/doc/interpreter/var.txi b/doc/interpreter/var.txi index 485e3d2c9946..0e929a2557f8 100644 --- a/doc/interpreter/var.txi +++ b/doc/interpreter/var.txi @@ -235,7 +235,7 @@ function y = foo () endfunction foo () -@print{} error: can't make function parameter y persistent +@error{} error: can't make function parameter y persistent @end group @end example diff --git a/scripts/strings/validatestring.m b/scripts/strings/validatestring.m index 0bdcc17261cf..e4de621c00e9 100644 --- a/scripts/strings/validatestring.m +++ b/scripts/strings/validatestring.m @@ -48,7 +48,7 @@ ## @result{} "red" ## ## validatestring ("b", @{"red", "green", "blue", "black"@}) -## @result{} error: validatestring: multiple unique matches were found for 'b': +## @error{} error: validatestring: multiple unique matches were found for 'b': ## blue, black ## @end group ## @end smallexample -- 2.23.0