Changeset a527a41 in git for libpolys/coeffs/flintcf_Q.cc


Ignore:
Timestamp:
Jul 9, 2018, 2:39:53 PM (5 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'a719bcf0b8dbc648b128303a49777a094b57592c')
Children:
43fa86cc32c42433e618d6c2978915bf8a580e66
Parents:
ac754db5ea554de8a6115ff7e914fb77dc57c434
Message:
move *Eati/*EatLong to numbers.cc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpolys/coeffs/flintcf_Q.cc

    rac754d ra527a41  
    4444  return s;
    4545}
    46 
    47 static const char* Eati(const char *s, int *i)
    48 {
    49 
    50   if (((*s) >= '0') && ((*s) <= '9'))
    51   {
    52     unsigned long ii=0L;
    53     do
    54     {
    55       ii *= 10;
    56       ii += *s++ - '0';
    57     }
    58     while (((*s) >= '0') && ((*s) <= '9'));
    59     *i=(int)ii;
    60   }
    61   else (*i) = 1;
    62   return s;
    63 }
    64 
    65 
    6646
    6747static void CoeffWrite(const coeffs r, BOOLEAN details)
     
    303283// we only read "monomials" (i.e. [-][digits][parameter]),
    304284// everythings else (+,*,^,()) is left to the singular interpreter
    305   const char *s=st;
     285  char *s=(char *)st;
    306286  *a=(number)omAlloc(sizeof(fmpq_poly_t));
    307287  fmpq_poly_init((fmpq_poly_ptr)(*a));
     
    329309    {
    330310      int i=1;
    331       s=Eati(s,&i);
     311      s=nEati(s,&i,0);
    332312      if (i!=1)
    333313      {
Note: See TracChangeset for help on using the changeset viewer.