diff libinterp/octave-value/ov-fcn-handle.cc @ 21124:95f8c8cdbffe

maint: Eliminate 'bool success' variable where possible. * ov-base-diag.cc (load_ascii): Remove success var, return true. * ov-base-int.cc (load_ascii): Remove success var, return true. * ov-base-sparse.cc (load_ascii): Remove success var, return true. * ov-bool-mat.cc (load_ascii): Remove success var, return true. * ov-cx-mat.cc (load_ascii): Remove success var, return true. * ov-fcn-handle.cc (set_fcn): Remove success var, return true. * ov-flt-cx-mat.cc (load_ascii): Remove success var, return true. * ov-flt-re-mat.cc (load_ascii): Remove success var, return true. * ov-perm.cc (load_ascii): Remove success var, return true. * ov-re-mat.cc (load_ascii): Remove success var, return true. * ov-str-mat.cc (load_ascii): Remove success var, return true. * ov-struct.cc (load_ascii): Remove success var, return true.
author Rik <rik@octave.org>
date Wed, 20 Jan 2016 21:54:36 -0800
parents dfcb9d74b253
children fcac5dbbf9ed
line wrap: on
line diff
--- a/libinterp/octave-value/ov-fcn-handle.cc	Wed Jan 20 21:30:55 2016 -0800
+++ b/libinterp/octave-value/ov-fcn-handle.cc	Wed Jan 20 21:54:36 2016 -0800
@@ -251,8 +251,6 @@
 octave_fcn_handle::set_fcn (const std::string &octaveroot,
                             const std::string& fpath)
 {
-  bool success = true;
-
   if (octaveroot.length () != 0
       && fpath.length () >= octaveroot.length ()
       && fpath.substr (0, octaveroot.length ()) == octaveroot
@@ -331,7 +329,7 @@
         }
     }
 
-  return success;
+  return true;
 }
 
 bool