source: git/Singular/ipshell.h @ 77ff8e

spielwiese
Last change on this file since 77ff8e was 77ff8e, checked in by Kai Krüger <krueger@…>, 26 years ago
* ChangeLog extra.cc grammar.y ipid.cc ipid.h iplib.cc * ipshell.cc ipshell.h mod2.h.in ring.cc structs.h tesths.cc Replaced ring *iiLocalRing[] by a stack (class namerec) To use old method define USE_IILOCALRING in mod2.h Old method incompatible with HAVE_NAMESPACES! git-svn-id: file:///usr/local/Singular/svn/trunk@2577 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 3.9 KB
Line 
1#ifndef IPSHELL_H
2#define IPSHELL_H
3/****************************************
4*  Computer Algebra System SINGULAR     *
5****************************************/
6/* $Id: ipshell.h,v 1.13 1998-10-15 14:08:37 krueger 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;
27#ifdef IILOCALRING
28extern ring   *iiLocalRing;
29#endif
30extern cmdnames cmds[];
31extern char *lastreserved;
32
33int     IsCmd(char *n, int & tok);
34BOOLEAN iiPStart(idhdl pn, sleftv * sl);
35BOOLEAN iiEStart(char* example, procinfo *pi);
36void    type_cmd(idhdl h);
37void    test_cmd(int i);
38void    list_cmd(int typ, const char* what, char * prefix, BOOLEAN iterate);
39void    iiWriteMatrix(matrix im, const char *n, int dim, int spaces=0);
40char *  iiStringMatrix(matrix im, int dim, char ch=',');
41void    killlocals(int v);
42int     exprlist_length(leftv v);
43char *  Tok2Cmdname(int i);
44char *  iiTwoOps(int t);
45int     IsPrime(int i);
46
47BOOLEAN iiWRITE(leftv res,leftv exprlist);
48BOOLEAN iiExport(leftv v, int toLev);
49BOOLEAN iiExport(leftv v, int toLev, idhdl &root);
50char *  iiGetLibName(procinfov v);
51char *  iiGetLibProcBuffer( procinfov pi, int part=1 );
52char *  iiProcName(char *buf, char & ct, char* &e);
53char *  iiProcArgs(char *e,BOOLEAN withParenth);
54BOOLEAN iiLibCmd( char *newlib, BOOLEAN tellerror=TRUE );
55leftv   iiMap(map theMap, char * what);
56void    iiMakeResolv(resolvente r, int length, int rlen, char * name, int typ0,
57           intvec ** weights=NULL);
58BOOLEAN jjMINRES(leftv res, leftv v);
59BOOLEAN jjBETTI(leftv res, leftv v);
60int     iiRegularity(lists L);
61leftv   singular_system(sleftv h);
62BOOLEAN jjSYSTEM(leftv res, leftv v);
63void    iiDebug();
64BOOLEAN iiCheckRing(int i);
65/* ================================================================== */
66/* Expressions : */
67BOOLEAN iiExprArith1(leftv res, sleftv* a, int op);
68BOOLEAN iiExprArith2(leftv res, sleftv* a, int op, sleftv* b,
69                     BOOLEAN proccall=FALSE);
70BOOLEAN iiExprArith3(leftv res, int op, leftv a, leftv b, leftv c);
71BOOLEAN iiExprArithM(leftv res, sleftv* a, int op);
72
73typedef BOOLEAN (*proc1)(leftv,leftv);
74
75#ifdef INIT_BUG
76void    jjInitTab1();
77#endif
78#ifdef GENTABLE
79typedef char * (*Proc1)(char *);
80struct sValCmd1
81{
82  proc1 p;
83  short cmd;
84  short res;
85  short arg;
86};
87
88typedef BOOLEAN (*proc2)(leftv,leftv,leftv);
89struct sValCmd2
90{
91  proc2 p;
92  short cmd;
93  short res;
94  short arg1;
95  short arg2;
96#ifdef PROFILING
97  short cnt;
98  int   t;
99#endif
100};
101
102typedef BOOLEAN (*proc3)(leftv,leftv,leftv,leftv);
103struct sValCmd3
104{
105  proc3 p;
106  short cmd;
107  short res;
108  short arg1;
109  short arg2;
110  short arg3;
111};
112struct sValCmdM
113{
114  proc1 p;
115  short cmd;
116  short res;
117  short number_of_args; /* -1: any, -2: any >0, .. */
118};
119extern struct sValCmd2 dArith2[];
120extern struct sValCmd1 dArith1[];
121extern struct sValCmd3 dArith3[];
122extern struct sValCmdM dArithM[];
123#endif
124
125/* ================================================================== */
126/* Assigments : */
127BOOLEAN iiAssign(leftv left, leftv right);
128
129typedef BOOLEAN (*proci)(leftv,leftv,Subexpr);
130struct sValAssign_sys
131{
132  proc1 p;
133  short res;
134  short arg;
135};
136
137struct sValAssign
138{
139  proci p;
140  short res;
141  short arg;
142};
143
144BOOLEAN iiParameter(leftv p);
145/* ================================================================== */
146int     iiDeclCommand(leftv sy, leftv name, int lev, int t, idhdl* root,
147  BOOLEAN init_b=TRUE);
148sleftv * iiMake_proc(idhdl pn, sleftv* sl);
149// from misc.cc:
150char *  showOption();
151BOOLEAN setOption(leftv res, leftv v);
152/* ================================================================== */
153char * versionString();
154#endif
155
Note: See TracBrowser for help on using the repository browser.