aboutsummaryrefslogtreecommitdiff
path: root/src/builder.cpp
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2006-08-21 05:54:52 +0000
committerMike Buland <eichlan@xagasoft.com>2006-08-21 05:54:52 +0000
commit4887f62bea708f24e03b3f926f2698c60a94c807 (patch)
tree77271e92cf517cbc2846897f7482c9df5efee124 /src/builder.cpp
parentdf5286fe3bca619beb4771da1ffa8ace9613e9e5 (diff)
downloadbuild-4887f62bea708f24e03b3f926f2698c60a94c807.tar.gz
build-4887f62bea708f24e03b3f926f2698c60a94c807.tar.bz2
build-4887f62bea708f24e03b3f926f2698c60a94c807.tar.xz
build-4887f62bea708f24e03b3f926f2698c60a94c807.zip
Getting there, it compiles, now for the fun sophisticated pieces where the
builder itself tells the lexer which tokens are functions, and which are target types.
Diffstat (limited to 'src/builder.cpp')
-rw-r--r--src/builder.cpp30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/builder.cpp b/src/builder.cpp
new file mode 100644
index 0000000..1ecbf05
--- /dev/null
+++ b/src/builder.cpp
@@ -0,0 +1,30 @@
1#include "builder.h"
2
3Builder::Builder()
4{
5}
6
7Builder::~Builder()
8{
9}
10
11void yyparse( Builder &bld );
12
13void Builder::load( const std::string &sFile )
14{
15 file = sFile;
16 scanBegin();
17 yyparse( *this );
18 scanEnd();
19}
20
21void Builder::error( YYLTYPE *locp, const char *msg )
22{
23 printf("%s\n", msg );
24}
25
26void Builder::error( const std::string &msg )
27{
28 printf("%s\n", msg.c_str() );
29}
30