Changeset 6d3ffec in git


Ignore:
Timestamp:
Apr 30, 1997, 5:25:34 PM (27 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
Children:
30637f47193073ce6445ef3c06828b2ec3d7d019
Parents:
01a20e5ae23d2ee1d178accd9cc46711ec2e30d1
Message:
* hannes: added Makefile to "touch -r mod2.h ...."


git-svn-id: file:///usr/local/Singular/svn/trunk@217 2c84dea3-7e68-4137-9b89-c4e89433aadc
Location:
Singular
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • Singular/Makefile.in

    r01a20e r6d3ffec  
    165165mod2.h: config.status config.cache mod2.h.in Makefile.in
    166166        ./config.status
    167         touch -r mod2.h configure configure.in Makefile.in
     167        touch -r mod2.h configure configure.in Makefile Makefile.in
    168168
    169169config.status config.cache : configure
  • Singular/febase.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: febase.cc,v 1.11 1997-04-29 19:54:48 obachman Exp $ */
     4/* $Id: febase.cc,v 1.12 1997-04-30 15:25:27 Singular Exp $ */
    55/*
    66* ABSTRACT: i/o system, handling of 'voices'
     
    3737class Voices
    3838{
    39   private:
    40     void Init()
    41     {
    42       memset(this,0,sizeof(*this));
    43       v_lineno = 1;
    44     }
    4539  public:
    4640    int    v_lineno;        // lineno, to restore in recursion
     
    5650
    5751  void Next();
    58   Voices() { Init(); }
     52  Voices() { v_lineno = 1; }
    5953  Voices * VFile(char* fname);
    6054  Voices * Buffer(char* buf, int t);
     
    7266int     levmax       = START_LEVMAX;
    7367Voices *currentVoice = NULL;
    74 Voices *FileAttribs  =(Voices *)Alloc(START_LEVMAX*sizeof(Voices));
     68Voices *FileAttribs  =(Voices *)Alloc0(START_LEVMAX*sizeof(Voices));
    7569short  *ifswitch     =(short *)Alloc0(START_LEVMAX*sizeof(short));
    7670        /*1 ifswitch==0: no if statement, else is invalid
     
    277271  v_echo     = si_echo;
    278272  fileVoice  = voice;
    279   yylineno   = 1;
     273  yylineno   = v_lineno   = 1;
    280274  if (files==NULL)
    281275  {
     
    299293                          levmax*sizeof(Voices),
    300294                          (levmax+16)*sizeof(Voices));
     295    memset(&FileAttribs[levmax],0,16*sizeof(Voices));
    301296    ifswitch=(short *)ReAlloc(ifswitch,
    302297                          levmax*sizeof(short),
     
    318313
    319314  currentVoice = &FileAttribs[voice];
    320   currentVoice->Init();
    321315}
    322316
     
    461455int exitFile()
    462456{
    463   int oldswitch;
    464 
    465   while ((voice > 0) && (inputswitch > 0))
    466   {
    467     exitVoice();
    468   }
    469   // now we have left all if-, else-, while-, for-, proc-levels
    470   // inside this file;
    471   // if the file is the terminal (inputswitch == 0) and
    472   // voice >0, so return 1 else return 0
    473   // (used for EXIT_CMD in CNTRLC-C-handling)
    474   oldswitch = inputswitch;
    475   exitVoice();
    476   #ifdef SIC
    477   return 1;
    478   #else
    479   if ((oldswitch)||(myynest<0)) return 0;
    480   else return 1;
    481   #endif
     457  /*4 first check for valid buffer type*/
     458  for (int i=voice; i>0; i--)
     459  {
     460    if (FileAttribs[i].typ == 0) break;
     461    if (FileAttribs[i].typ == BT_file)
     462    {
     463      while ((BT_file != currentVoice->typ)
     464      && (voice > 0))
     465      {
     466        exitVoice();
     467      }
     468      exitVoice();
     469    }
     470  }
    482471}
    483472
     
    598587void I_FEbase(void)
    599588{
    600   FileAttribs[0].files       = yyin = stdin;
    601   FileAttribs[0].filename    = mstrdup("STDIN");
    602   yylineno = 1;
    603   currentVoice = &FileAttribs[0];
     589  currentVoice=FileAttribs[0].VFile("STDIN");
     590  //FileAttribs[0].files       = yyin = stdin;
     591  //FileAttribs[0].filename    = mstrdup("STDIN");
     592  //yylineno = 1;
     593  //currentVoice = &FileAttribs[0];
    604594}
    605595
  • Singular/grammar.y

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: grammar.y,v 1.7 1997-04-10 16:34:42 Singular Exp $ */
     4/* $Id: grammar.y,v 1.8 1997-04-30 15:25:27 Singular Exp $ */
    55/*
    66* ABSTRACT: SINGULAR shell grammatik
     
    343343          {
    344344            ifswitch[voice]=0;
     345            exitFile();
    345346            /* Print("exit found\n"); */
    346             YYACCEPT;
    347347          }
    348348        | SYS_BREAK
  • Singular/intvec.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR      *
    33*****************************************/
    4 /* $Id: intvec.cc,v 1.5 1997-04-12 16:04:37 Singular Exp $ */
     4/* $Id: intvec.cc,v 1.6 1997-04-30 15:25:28 Singular Exp $ */
    55/*
    66* ABSTRACT: class intvec: lists/vectors of integers
     
    7777}
    7878
    79 char * intvec::ivString()
     79char * intvec::ivString(int mat,int spaces)
    8080{
    8181  StringSetS("");
    82   if (col == 1)
     82  if ((col == 1)&&(mat!=INTMAT_CMD))
    8383  {
    8484    for (int i=0; i<row; i++)
     
    105105        }
    106106      }
    107       if (j+1<row) StringAppend("\n");
     107      if (j+1<row)
     108      {
     109        StringAppend("\n");
     110        if (spaces>0) StringAppend("%-*.*s",spaces,spaces," ");
     111      } 
    108112    }
    109113  }
     
    116120}
    117121
    118 void intvec::show(int spaces)
     122void intvec::show(int mat,int spaces)
    119123{
    120124  if (spaces>0)
    121     Print("%-*.*s%s",spaces,spaces," ",ivString());
     125    Print("%-*.*s%s",spaces,spaces," ",ivString(mat,spaces));
    122126  else
    123     PrintS(ivString());
     127    PrintS(ivString(mat,0));
    124128}
    125129
  • Singular/intvec.h

    r01a20e r6d3ffec  
    44*  Computer Algebra System SINGULAR     *
    55****************************************/
    6 /* $Id: intvec.h,v 1.3 1997-04-09 12:19:45 Singular Exp $ */
     6/* $Id: intvec.h,v 1.4 1997-04-30 15:25:29 Singular Exp $ */
    77/*
    88* ABSTRACT: class intvec: lists/vectors of integers
     
    5151    int  rows() const { return row; }
    5252    void length(int l) { row = l; col = 1; }
    53     void show(int spaces=0);
     53    void show(int mat=0,int spaces=0);
    5454    void makeVector() { row*=col;col=1; }
    5555    // keiner (ausser obachman) darf das folgenden benutzen !!!
    5656    int * ivGetVec() { return v; }
    5757    char * String();
    58     char * ivString();
     58    char * ivString(int mat=0,int spaces=0);
    5959    ~intvec()
    6060       {
  • Singular/iparith.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: iparith.cc,v 1.24 1997-04-28 09:57:54 Singular Exp $ */
     4/* $Id: iparith.cc,v 1.25 1997-04-30 15:25:30 Singular Exp $ */
    55/*
    66* ABSTRACT: table driven kernel interface, used by interpreter
     
    11761176static BOOLEAN jjKLAMMER(leftv res, leftv u, leftv v)
    11771177{
     1178  if(u->name==NULL) return TRUE;
    11781179  char * n = (char *)AllocL(strlen(u->name) + 6);
    11791180  sprintf(n,"%s(%d)",u->name,(int)v->Data());
     
    42224223  }
    42234224  fprintf(outfile,"/*---------------------------------------------*/\n");
    4224   char ops[]="=><+*/[.^,%(";
     4225  char ops[]="=><+*/[.^,%(;";
    42254226  for(i=0;ops[i]!='\0';i++)
    42264227    fprintf(outfile,"// token %d : %c\n", (int)ops[i], ops[i]);
  • Singular/ipshell.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: ipshell.cc,v 1.7 1997-04-28 17:47:15 Singular Exp $ */
     4/* $Id: ipshell.cc,v 1.8 1997-04-30 15:25:32 Singular Exp $ */
    55/*
    66* ABSTRACT:
     
    640640  if (r==NULL) return TRUE;
    641641  res->data=(char *)syBetti(r,len,&reg);
    642 // int i,j;
    643 //  for(i=0;i<betti->rows();i++)
    644 //  {
    645 //    Print("%2d:",i);
    646 //    for(j=1;j<=betti->cols();j++)
    647 //    {
    648 //      Print(" %5d",IMATELEM(*betti,i+1,j));
    649 //    }
    650 //    PrintLn();
    651 //  }
    652642  Free((ADDRESS)r,(len)*sizeof(ideal));
    653643  return FALSE;
  • Singular/ring.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: ring.cc,v 1.8 1997-04-18 15:49:40 Singular Exp $ */
     4/* $Id: ring.cc,v 1.9 1997-04-30 15:25:33 Singular Exp $ */
    55
    66/*
     
    288288    {
    289289      while ((ch!=fftable[l]) && (fftable[l])) l++;
    290       if (fftable[l]==0) ch = IsPrime(ch);
     290      if (fftable[l]==0)
     291      {
     292        ch = IsPrime(ch);
     293      } 
    291294      else
    292295      {
    293296        char *m[1]={(char *)sNoName};
    294297        nfSetChar(ch,m);
    295         if(errorreported) ch=IsPrime(ch);
    296         else ffChar=TRUE;
     298        if(errorreported)
     299        {
     300           errorreported=0;
     301           ch=IsPrime(ch);
     302        }
     303        else
     304        {
     305          ffChar=TRUE;
     306        } 
    297307      }
    298308    }
     
    319329      else hs=pn;
    320330      hs->CleanUp();
    321       Free((ADDRESS)hs,sizeof(sleftv));
    322       if (ffChar) pn->next=NULL;
     331      if (ffChar)
     332      {
     333        pn->next=NULL;
     334        Free((ADDRESS)hs,sizeof(sleftv));
     335      } 
    323336      else pn=NULL;
    324337    }
  • Singular/subexpr.cc

    r01a20e r6d3ffec  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: subexpr.cc,v 1.15 1997-04-22 14:50:28 Singular Exp $ */
     4/* $Id: subexpr.cc,v 1.16 1997-04-30 15:25:34 Singular Exp $ */
    55
    66/*
     
    116116        case INTVEC_CMD:
    117117        case INTMAT_CMD:
    118           ((intvec *)d)->show(spaces);
     118          ((intvec *)d)->show(t,spaces);
    119119          break;
    120120        case RING_CMD:
     
    664664        return rString((ring)d);
    665665      } 
    666   #ifdef TEST
    667666      default:
     667        #ifdef TEST
    668668        ::Print("String:unknown type %s(%d)", Tok2Cmdname(Typ()),Typ());
     669        #endif
    669670        return NULL;
    670   #endif
    671671    } /* end switch: (Typ()) */
    672672    return mstrdup(s);
Note: See TracChangeset for help on using the changeset viewer.