diff libinterp/corefcn/dirfns.cc @ 21078:49852ff04747

maint: Remove unnecessary declarations of retval. * __pchip_deriv__.cc, data.cc, dirfns.cc, error.cc, file-io.cc, input.cc, load-path.cc, octave-link.cc, strfns.cc, sysdep.cc, time.cc, toplev.cc, urlwrite.cc, ov-cell.cc, ov.cc: Remove unnecessary declarations of retval.
author Rik <rik@octave.org>
date Fri, 15 Jan 2016 13:40:34 -0800
parents fc9cca99b2de
children e39e05d90788
line wrap: on
line diff
--- a/libinterp/corefcn/dirfns.cc	Fri Jan 15 10:52:48 2016 -0800
+++ b/libinterp/corefcn/dirfns.cc	Fri Jan 15 13:40:34 2016 -0800
@@ -523,8 +523,9 @@
 @deftypefn {} {} fnmatch (@var{pattern}, @var{string})\n\
 Return true or false for each element of @var{string} that matches any of\n\
 the elements of the string array @var{pattern}, using the rules of\n\
+filename pattern matching.\n\
 \n\
-filename pattern matching.  For example:\n\
+For example:\n\
 \n\
 @example\n\
 @group\n\
@@ -535,8 +536,6 @@
 @seealso{glob, regexp}\n\
 @end deftypefn")
 {
-  octave_value retval;
-
   if (args.length () != 2)
     print_usage ();
 
@@ -545,7 +544,7 @@
 
   glob_match pattern (file_ops::tilde_expand (pat));
 
-  return octave_value (pattern.match (str));
+  return ovl (pattern.match (str));
 }
 
 DEFUN (filesep, args, ,