Changeset 3bb3e6a in git for Singular/iparith.cc


Ignore:
Timestamp:
May 24, 1998, 2:09:23 PM (26 years ago)
Author:
Olaf Bachmann <obachman@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
45f7bfcca3edf19f70b4d4e83236758f8d71c6da
Parents:
96b804631b095d8928ec2c241293ce9015190de7
Message:
* status with sleep


git-svn-id: file:///usr/local/Singular/svn/trunk@1961 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/iparith.cc

    r96b804 r3bb3e6a  
    267267  { "sres",        0, SRES_CMD ,          CMD_2},
    268268  #endif
    269   { "status",      0, STATUS_CMD,         CMD_23},
     269  { "status",      0, STATUS_CMD,         CMD_M},
    270270  { "std",         0, STD_CMD ,           CMD_12},
    271271  { "string",      0, STRING_CMD ,        ROOT_DECL_LIST},
     
    39563956  return b;
    39573957}
     3958static BOOLEAN jjCALL3ARG(leftv res, leftv u)
     3959{
     3960  leftv v = u->next;
     3961  leftv w = v->next;
     3962  u->next = NULL;
     3963  v->next = NULL;
     3964  BOOLEAN b = iiExprArith3(res, iiOp, u, v, w);
     3965  u->next = v;
     3966  v->next = w;
     3967  return b;
     3968}
     3969 
    39583970static BOOLEAN jjCOEF_M(leftv res, leftv v)
    39593971{
     
    42984310  return FALSE;
    42994311}
     4312
     4313static BOOLEAN jjSTATUS_M(leftv res, leftv v)
     4314{
     4315  if ((v->Typ() != LINK_CMD) ||
     4316      (v->next->Typ() != STRING_CMD) ||
     4317      (v->next->next->Typ() != STRING_CMD) ||
     4318      (v->next->next->next->Typ() != INT_CMD))
     4319    return TRUE;
     4320  jjSTATUS3(res, v, v->next, v->next->next);
     4321#ifdef HAVE_SLEEP
     4322  if (((int) res->data) == 0)
     4323  {
     4324    sleep((int) v->next->next->next->Data());
     4325    jjSTATUS3(res, v, v->next, v->next->next);
     4326  }
     4327#endif
     4328  return FALSE;
     4329}
     4330
     4331     
    43004332/*=================== operations with many arg.: table =================*/
    43014333/* number_of_args:  -1: any, -2: any >0, .. */
     
    43264358,{jjTEST,      TEST_CMD,        NONE,               -2 }
    43274359,{iiWRITE,     WRITE_CMD,       NONE,               -2 }
     4360,{jjCALL2ARG,  STATUS_CMD,      STRING_CMD,          2 }
     4361,{jjCALL3ARG,  STATUS_CMD,      INT_CMD,             3 }
     4362,{jjSTATUS_M,  STATUS_CMD,      INT_CMD,             4 }
    43284363,{NULL,        0,               0,                  0  }
    43294364};
Note: See TracChangeset for help on using the changeset viewer.