help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

integers in oct-files


From: John W. Eaton
Subject: integers in oct-files
Date: Wed, 12 May 1999 12:48:46 -0500 (CDT)

On 22-Apr-1999, Stef Pillaert <address@hidden> wrote:

| I have a lot of .cc files, that I compiled to .oct files. I used integers
| in them (multiplying a matrix with an int, calls like "octave_value(i)"
| where i is an int, ...)
| 
| This all worked fine under octave 2.0.12 (at least, as I remember, it has
| been a while...), but under 2.0.14 I have to convert all those integers to
| doubles. Is this normal? Or has it something to do with installing RedHat
| Linux 5.2 (and probably newer versions of c++)? 
| 
| Sorry if this is a dumb question, I've been out of the whole thing for a
| long period now...

I'm not sure what change made it necessary, but yes, you need to write

  int i;

  ...

  octave_value ov (static_cast<double> (i));

or similar now.

jwe




reply via email to

[Prev in Thread] Current Thread [Next in Thread]