Jens Schmidt on Wed, 08 Aug 2018 11:51:54 +0200


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

Re: Missing function declaration "diviu_rem" for older code


Am 08.08.2018, 10:08 schrieb Bill Allombert
<Bill.Allombert@math.u-bordeaux.fr>:

> On Wed, Aug 08, 2018 at 07:59:37AM +0200, Jens Schmidt wrote:
> > diviu_rem has been renamed to absdiviu_rem. Older Code will not
> > compile because there is no compatibility declaration to change
> > calls from diviu_rem to absdiviu_rem.  
> 
> Hello Jens,
> 
> To complement what Karim said:
> Do you have code that use diviu_rem ?
> What happens when the first parameter is negative ?
> 
> Cheers,
> Bill
> 

Hmm. The first parameter in my code is never negative because diviu_rem
is used for easy conversion of numeral systems without a sign. 

  ...
  if (signe(N) < 0) setsigne(N, 1);
 
  ...
 
  for (z = 0; signe(N); ) {     /* convert N into numeral of base */
    N = diviu_rem(N, base, &k);
    numeral[z++] = k;
  }
  ...


LG - Jens