]> www.ginac.de Git - ginac.git/blob - ginsh/ginsh.h
* Streamlining by Peter Eisentraut <petere@debian.org>.
[ginac.git] / ginsh / ginsh.h
1 /** @file ginsh.h
2  *
3  *  Global definitions for ginsh.
4  *
5  *  GiNaC Copyright (C) 1999-2005 Johannes Gutenberg University Mainz, Germany
6  *
7  *  This program is free software; you can redistribute it and/or modify
8  *  it under the terms of the GNU General Public License as published by
9  *  the Free Software Foundation; either version 2 of the License, or
10  *  (at your option) any later version.
11  *
12  *  This program is distributed in the hope that it will be useful,
13  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  *  GNU General Public License for more details.
16  *
17  *  You should have received a copy of the GNU General Public License
18  *  along with this program; if not, write to the Free Software
19  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
20  */
21
22 #ifndef GINSH_H
23 #define GINSH_H
24
25 #include <stdio.h>
26 #include <stdlib.h>
27 #include <string.h>
28
29 #include <map>
30 #include <iostream>
31 #include <string>
32
33 using namespace std;
34
35 #ifdef HAVE_READLINE_READLINE_H
36 extern "C" {
37 #include <readline/readline.h>
38 }
39 #endif
40
41 #ifdef HAVE_READLINE_HISTORY_H
42 extern "C" {
43 #include <readline/history.h>
44 }
45 #endif
46
47 #ifdef IN_GINAC
48 #include "ginac.h"
49 #else
50 #include <ginac/ginac.h>
51 #endif
52
53 using namespace GiNaC;
54
55 // yacc stack type
56 #define YYSTYPE ex
57
58 // lex functions/variables
59 extern int yyerror(char *s);
60 extern int yylex(void);
61 extern char *yytext;
62 extern FILE *yyin;
63
64 // List of input files to be processed
65 extern int num_files;
66 extern char **file_list;
67
68 // Table of all used symbols
69 typedef map<string, symbol> sym_tab;
70 extern sym_tab syms;
71
72 // Type of symbols to generate (real or complex)
73 extern unsigned symboltype;
74
75 #endif