teuben / nemo

a Stellar Dynamics Toolbox (Not Everybody Must Observe)
https://astronemo.readthedocs.io
GNU General Public License v2.0
59 stars 42 forks source link

incompatible function pointers.... #151

Open teuben opened 3 months ago

teuben commented 3 months ago

For future strict compilers: snapgrid and snapmradii warn about incompatible function pointer usage. this now failed on a recent mac, but not on current linux yet (gcc 14 also fails this)

teuben commented 1 month ago

the full list includes snapcmp, quadforce, snapmstat

teuben commented 1 month ago

The proper protype should be:

local int cmpreal(const void *ap, const void *bp)
 {

  real *a = (real *) ap;
  real *b = (real *) bp;
  return (*a < *b ? -1 : *a > *b ? 1 : 0);
 }