carlodefalco / octave-mpi

Octave bindings for basic Message Passing Interface (MPI) functions for parallel computing.
GNU General Public License v3.0
4 stars 1 forks source link

mpi needs an update for octave 6.x #5

Open matzeri opened 2 years ago

matzeri commented 2 years ago

It seems mpi needs an update for octave 6.x

On Cygwin with 6.4 I see:

MPI_Iprobe.cc:68:17: warning: ‘error_state’ is deprecated: [6]: this variable is obsolete and always has the value 0 [-Wdeprecated-declarations]
   68 |           if (! error_state)
      |                 ^~~~~~~~~~~
carlodefalco commented 2 years ago

Thanks for the report.

If I understand correctly that Is just a warning that can be ignored.

In Octave 6, if an errore occurs an exception will be thrown causing the function to return so that the if statement Is not even reached.

If the if statement is reached It means no error occurred so it Is correct that error_state is assumed to be false.

Keeping the code this way maximizes backward compatibility I think, so it should be changed only when error_state is removed ...

c.

carlodefalco commented 2 years ago

Just starting to experiment with Octave 7.1 ... If I understand correctly, it appears that now error_state has been removed, so it is indeed time to address this issue. This will break compatibility with Octave 5, but I think it is OK