# HG changeset patch # User Rik # Date 1444691292 25200 # Node ID d35201e5ce5d112889c407683732665c4f06826a # Parent 27c091f4b66dc3d462eb18c947d4d752254a40f4 Fix compilation of jit broken by dd6345fd8a97 (bug #46191). * jit-typeinfo.cc (octave_jit_compute_nelem): Use rng.numel() rather than deprecated nelem(). * jit-typeinfo.cc (octave_jit_ginvalid_index): Call gripe_invalid_index (-1) now that 0-argument form of function has been removed. * jit-typeinfo.h (jit_range): Use numel() rather than nelem() for Range. * pt-jit.cc (trip_count): Use numel() rather than nelem() for Range. diff -r 27c091f4b66d -r d35201e5ce5d libinterp/corefcn/jit-typeinfo.cc --- a/libinterp/corefcn/jit-typeinfo.cc Mon Oct 12 23:28:29 2015 +0200 +++ b/libinterp/corefcn/jit-typeinfo.cc Mon Oct 12 16:08:12 2015 -0700 @@ -115,7 +115,7 @@ octave_jit_compute_nelem (double base, double limit, double inc) { Range rng = Range (base, limit, inc); - return rng.nelem (); + return rng.numel (); } extern "C" void @@ -221,7 +221,9 @@ extern "C" void octave_jit_ginvalid_index (void) { - gripe_invalid_index (); + // FIXME: 0-argument form of gripe_invalid_index removed in cset dd6345fd8a97 + // Report -1 as the bad index for all occurrences. + gripe_invalid_index (-1); } extern "C" void diff -r 27c091f4b66d -r d35201e5ce5d libinterp/corefcn/jit-typeinfo.h --- a/libinterp/corefcn/jit-typeinfo.h Mon Oct 12 23:28:29 2015 +0200 +++ b/libinterp/corefcn/jit-typeinfo.h Mon Oct 12 16:08:12 2015 -0700 @@ -45,7 +45,7 @@ jit_range { jit_range (const Range& from) : base (from.base ()), limit (from.limit ()), - inc (from.inc ()), nelem (from.nelem ()) + inc (from.inc ()), nelem (from.numel ()) { } operator Range () const diff -r 27c091f4b66d -r d35201e5ce5d libinterp/corefcn/pt-jit.cc --- a/libinterp/corefcn/pt-jit.cc Mon Oct 12 23:28:29 2015 +0200 +++ b/libinterp/corefcn/pt-jit.cc Mon Oct 12 16:08:12 2015 -0700 @@ -2170,7 +2170,7 @@ if (bounds.is_range ()) { Range rng = bounds.range_value (); - return rng.nelem (); + return rng.numel (); } // unsupported type