changeset 31364:39230ec95b99

build: Silence compilation warning -Wunused-but-set-variable in oct-string.cc (bug #63210) * oct-string.cc (rational_approx): Delete local variable 'm'.
author Rik <rik@octave.org>
date Sat, 29 Oct 2022 18:25:33 -0700
parents af38813e5b89
children e4a52cb9ce41
files liboctave/util/oct-string.cc
diffstat 1 files changed, 0 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/util/oct-string.cc	Sat Oct 29 18:07:10 2022 -0700
+++ b/liboctave/util/oct-string.cc	Sat Oct 29 18:25:33 2022 -0700
@@ -728,7 +728,6 @@
       T n = octave::math::round (val);
       T d = 1;
       T frac = val - n;
-      int m = 0;
 
       std::ostringstream init_buf;
       init_buf.flags (std::ios::fixed);
@@ -760,7 +759,6 @@
           buf.flags (std::ios::fixed);
           buf << std::setprecision (0) << static_cast<int> (n)
               << '/' << static_cast<int> (d);
-          m++;
 
           if (n < 0 && d < 0)
             {