source: git/Singular/ipshell.h @ d2b2a7

spielwiese
Last change on this file since d2b2a7 was 057e93c, checked in by Hans Schönemann <hannes@…>, 26 years ago
* Fri Feb 27 15:02:10 MET 1998 hannes new input scheme: many modifications to febase.h, febase.inc, febase.cc, scanner.l, grammar.y, iplib.cc, ipshell.{h,cc} git-svn-id: file:///usr/local/Singular/svn/trunk@1183 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 3.8 KB
Line 
1#ifndef IPSHELL_H
2#define IPSHELL_H
3/****************************************
4*  Computer Algebra System SINGULAR     *
5****************************************/
6/* $Id: ipshell.h,v 1.11 1998-02-27 14:06:21 Singular Exp $ */
7/*
8* ABSTRACT
9*/
10#include <stdio.h>
11#include "structs.h"
12#include "subexpr.h"
13
14extern int  traceit ;
15#define TRACE_SHOW_PROC   1
16#define TRACE_SHOW_LINENO 2
17#define TRACE_SHOW_LINE   4
18#define TRACE_SHOW_RINGS  8
19#define TRACE_SHOW_LINE1  16
20extern leftv iiCurrArgs;
21extern int iiOp; /* the current operation*/
22extern int  myynest;
23extern char *  currid;
24extern char * thisfile;
25extern int     iiRETURNEXPR_len;
26extern sleftv *iiRETURNEXPR;
27extern ring   *iiLocalRing;
28extern cmdnames cmds[];
29extern char *lastreserved;
30
31int     IsCmd(char *n, int & tok);
32BOOLEAN iiPStart(idhdl pn, sleftv * sl);
33BOOLEAN iiEStart(char* example, procinfo *pi);
34void    type_cmd(idhdl h);
35void    test_cmd(int i);
36void    list_cmd(int typ, const char* what, char * prefix, BOOLEAN iterate);
37void    iiWriteMatrix(matrix im, const char *n, int dim, int spaces=0);
38char *  iiStringMatrix(matrix im, int dim, char ch=',');
39void    killlocals(int v);
40int     exprlist_length(leftv v);
41char *  Tok2Cmdname(int i);
42char *  iiTwoOps(int t);
43int     IsPrime(int i);
44
45BOOLEAN iiWRITE(leftv res,leftv exprlist);
46BOOLEAN iiExport(leftv v, int toLev);
47BOOLEAN iiExport(leftv v, int toLev, idhdl &root);
48char *  iiGetLibName(procinfov v);
49char *  iiGetLibProcBuffer( procinfov pi, int part=1 );
50char *  iiProcName(char *buf, char & ct, char* &e);
51char *  iiProcArgs(char *e,BOOLEAN withParenth);
52BOOLEAN iiLibCmd( char *newlib, BOOLEAN tellerror=TRUE );
53leftv   iiMap(map theMap, char * what);
54void    iiMakeResolv(resolvente r, int length, int rlen, char * name, int typ0,
55           intvec ** weights=NULL);
56BOOLEAN jjMINRES(leftv res, leftv v);
57BOOLEAN jjBETTI(leftv res, leftv v);
58int     iiRegularity(lists L);
59leftv   singular_system(sleftv h);
60BOOLEAN jjSYSTEM(leftv res, leftv v);
61void    iiDebug();
62BOOLEAN iiCheckRing(int i);
63/* ================================================================== */
64/* Expressions : */
65BOOLEAN iiExprArith1(leftv res, sleftv* a, int op);
66BOOLEAN iiExprArith2(leftv res, sleftv* a, int op, sleftv* b,
67                     BOOLEAN proccall=FALSE);
68BOOLEAN iiExprArith3(leftv res, int op, leftv a, leftv b, leftv c);
69BOOLEAN iiExprArithM(leftv res, sleftv* a, int op);
70
71typedef BOOLEAN (*proc1)(leftv,leftv);
72
73#ifdef INIT_BUG
74void    jjInitTab1();
75#endif
76#ifdef GENTABLE
77typedef char * (*Proc1)(char *);
78struct sValCmd1
79{
80  proc1 p;
81  short cmd;
82  short res;
83  short arg;
84};
85
86typedef BOOLEAN (*proc2)(leftv,leftv,leftv);
87struct sValCmd2
88{
89  proc2 p;
90  short cmd;
91  short res;
92  short arg1;
93  short arg2;
94#ifdef PROFILING
95  short cnt;
96  int   t;
97#endif
98};
99
100typedef BOOLEAN (*proc3)(leftv,leftv,leftv,leftv);
101struct sValCmd3
102{
103  proc3 p;
104  short cmd;
105  short res;
106  short arg1;
107  short arg2;
108  short arg3;
109};
110struct sValCmdM
111{
112  proc1 p;
113  short cmd;
114  short res;
115  short number_of_args; /* -1: any, -2: any >0, .. */
116};
117extern struct sValCmd2 dArith2[];
118extern struct sValCmd1 dArith1[];
119extern struct sValCmd3 dArith3[];
120extern struct sValCmdM dArithM[];
121#endif
122
123/* ================================================================== */
124/* Assigments : */
125BOOLEAN iiAssign(leftv left, leftv right);
126
127typedef BOOLEAN (*proci)(leftv,leftv,Subexpr);
128struct sValAssign_sys
129{
130  proc1 p;
131  short res;
132  short arg;
133};
134
135struct sValAssign
136{
137  proci p;
138  short res;
139  short arg;
140};
141
142BOOLEAN iiParameter(leftv p);
143/* ================================================================== */
144int     iiDeclCommand(leftv sy, leftv name, int lev, int t, idhdl* root,
145  BOOLEAN init_b=TRUE);
146sleftv * iiMake_proc(idhdl pn, sleftv* sl);
147// from misc.cc:
148void   showOption();
149BOOLEAN setOption(leftv res, leftv v);
150/* ================================================================== */
151char * versionString();
152#endif
153
Note: See TracBrowser for help on using the repository browser.