Changeset bcd557 in git for Singular/iplib.cc


Ignore:
Timestamp:
Jun 18, 1998, 7:32:13 PM (26 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
300a346b7aab2a310ad9542b7b9ed1e68c1a8be2
Parents:
0a53a908f6c1a64a4e1f1b05085604516b79f95d
Message:
* hannes:error handling (grammar.y iparith.cc iplib.cc)
          (leaving of levels, local vars, messages,..)


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

Legend:

Unmodified
Added
Removed
  • Singular/iplib.cc

    r0a53a9 rbcd557  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: iplib.cc,v 1.30 1998-06-13 12:44:42 krueger Exp $ */
     4/* $Id: iplib.cc,v 1.31 1998-06-18 17:32:12 Singular Exp $ */
    55/*
    66* ABSTRACT: interpreter: LIB and help
     
    130130  char buf[256], *s = NULL, *p;
    131131  long procbuflen;
    132  
     132
    133133  FILE * fp = feFopen( pi->libname, "rb", NULL, TRUE );
    134134  if (fp==NULL)
     
    320320  idhdl ns = namespaceroot->get(plib,0, TRUE);
    321321  FreeL(plib);
    322   if(ns != NULL) {
     322  if(ns != NULL)
     323  {
    323324    namespaceroot->push(IDPACKAGE(ns), IDID(ns));
    324325    //printf("iiMake_proc: namespace found.\n");
    325   } else {
     326  }
     327  else
     328  {
    326329    namespaceroot->push(namespaceroot->root->pack, "toplevel");
    327330    //printf("iiMake_proc: staying in TOP-LEVEL\n");
    328331  }
    329332#else /* HAVE_NAMESPACES */
    330   if(pi->is_static && myynest==0) {
     333  if(pi->is_static && myynest==0)
     334  {
    331335    Werror("'%s::%s()' is a local procedure and cannot be accessed by an user.",
    332336           pi->libname, pi->procname);
     
    346350#endif
    347351#if 1
    348   if(pi->language == LANG_SINGULAR) err=iiPStart(pn,sl);
    349   if(pi->language == LANG_C)
     352  if(pi->language == LANG_SINGULAR)
     353  {
     354    err=iiPStart(pn,sl);
     355  }
     356  else if(pi->language == LANG_C)
    350357  {
    351358    leftv res = (leftv)Alloc0(sizeof(sleftv));
     
    408415  if (iiCurrArgs!=NULL)
    409416  {
    410     Warn("too many arguments for %s",IDID(pn));
     417    if (!err) Warn("too many arguments for %s",IDID(pn));
    411418    iiCurrArgs->CleanUp();
    412419    Free((ADDRESS)iiCurrArgs,sizeof(sleftv));
     
    416423  namespaceroot->pop();
    417424#endif /* HAVE_NAMESPACES */
    418   if (err) return NULL;
     425  if (err)
     426    return NULL;
    419427  return &iiRETURNEXPR[myynest+1];
    420428}
Note: See TracChangeset for help on using the changeset viewer.