changeset 14435:f312918f16d2

doc: Add cross-references between fgets and fgetl in docstrings. file-io.cc (fgets, fgetl): Add cross-references between fgets and fgetl in docstrings.
author Rik <octave@nomad.inbox5.com>
date Mon, 05 Mar 2012 13:18:51 -0800
parents 3d4f7631baff
children 12097d20a23e
files src/file-io.cc
diffstat 1 files changed, 10 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/file-io.cc	Mon Mar 05 08:43:36 2012 -0800
+++ b/src/file-io.cc	Mon Mar 05 13:18:51 2012 -0800
@@ -302,7 +302,8 @@
 
 DEFUN (fgetl, args, ,
   "-*- texinfo -*-\n\
-@deftypefn {Built-in Function} {} fgetl (@var{fid}, @var{len})\n\
+@deftypefn  {Built-in Function} {@var{str} =} fgetl (@var{fid})\n\
+@deftypefnx {Built-in Function} {@var{str} =} fgetl (@var{fid}, @var{len})\n\
 Read characters from a file, stopping after a newline, or EOF,\n\
 or @var{len} characters have been read.  The characters read, excluding\n\
 the possible trailing newline, are returned as a string.\n\
@@ -311,7 +312,9 @@
 character.\n\
 \n\
 If there are no more characters to read, @code{fgetl} returns @minus{}1.\n\
-@seealso{fread, fscanf}\n\
+\n\
+To read a line and return the terminating newline see @code{fgets}.\n\
+@seealso{fgets, fputs, fopen, fread, fscanf}\n\
 @end deftypefn")
 {
   static std::string who = "fgetl";
@@ -350,8 +353,8 @@
 
 DEFUN (fgets, args, ,
   "-*- texinfo -*-\n\
-@deftypefn  {Built-in Function} {} fgets (@var{fid})\n\
-@deftypefnx {Built-in Function} {} fgets (@var{fid}, @var{len})\n\
+@deftypefn  {Built-in Function} {@var{str} =} fgets (@var{fid})\n\
+@deftypefnx {Built-in Function} {@var{str} =} fgets (@var{fid}, @var{len})\n\
 Read characters from a file, stopping after a newline, or EOF,\n\
 or @var{len} characters have been read.  The characters read, including\n\
 the possible trailing newline, are returned as a string.\n\
@@ -360,7 +363,9 @@
 character.\n\
 \n\
 If there are no more characters to read, @code{fgets} returns @minus{}1.\n\
-@seealso{fputs, fopen, fread, fscanf}\n\
+\n\
+To read a line and discard the terminating newline see @code{fgetl}.\n\
+@seealso{fgetl, fputs, fopen, fread, fscanf}\n\
 @end deftypefn")
 {
   static std::string who = "fgets";