-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
47 lines (35 loc) · 824 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#include <map>
#include <vector>
#include "parser.h"
#include "plotter.h"
#include "realplotter2d.h"
#include "realparser.h"
#include <iostream>
// Temp
#include "scanner.h"
#include "defaultscanner.h"
#include "stringmodifier.h"
using std::cout;
using std::endl;
using std::map;
using std::vector;
using namespace ParsePlot;
int main()
{
/*RealPlotter2D::ResultMap m;
Parser<double> *parse = new RealParser();
Plotter<double> *plot = new RealPlotter2D(parse);
plot->Plot(m, "x^2+4x");
delete parse;
delete plot;*/
Scanner *s = new DefaultScanner();
s->Scan("20.94588+45*(35-2)*3");
cout << "TOKENS:" << endl;
cout << "-------" << endl << endl;
while (s->HasNext())
{
cout << "TOKEN: " << s->Next()->GetValue() << endl;
}
delete s;
return 0;
}