summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Thurston <thurston@complang.org>2013-04-16 22:48:45 -0400
committerAdrian Thurston <thurston@complang.org>2013-04-16 22:48:45 -0400
commit47f0ae11f2cfddc3aa7f98c1eadb19df329b9d67 (patch)
tree912df71ced0c0b6a24e18793172fc3636e2e8d59
parent48d12aa7b884d46d70751f06d286fb245c49f9e6 (diff)
downloadcolm-47f0ae11f2cfddc3aa7f98c1eadb19df329b9d67.tar.gz
renamed the variable holding program text+rodata to colm_object
-rw-r--r--colm/codegen.cc2
-rw-r--r--colm/colm.h4
-rw-r--r--colm/loadcolm.cc6
-rw-r--r--colm/loadinit.cc4
-rw-r--r--colm/pdacodegen.cc4
-rw-r--r--colm/program.h2
6 files changed, 11 insertions, 11 deletions
diff --git a/colm/codegen.cc b/colm/codegen.cc
index 63ec9151..660f372e 100644
--- a/colm/codegen.cc
+++ b/colm/codegen.cc
@@ -35,7 +35,7 @@ void FsmCodeGen::writeMain( long activeRealm )
"{\n"
" struct colm_program *prg;\n"
" int exitStatus;\n"
- " prg = colm_new_program( &main_runtimeData, " << activeRealm << " );\n"
+ " prg = colm_new_program( &colm_object, " << activeRealm << " );\n"
" colm_run_program( prg, argc, argv );\n"
" exitStatus = colm_delete_program( prg );\n"
" return exitStatus;\n"
diff --git a/colm/colm.h b/colm/colm.h
index a9377ff6..13df281a 100644
--- a/colm/colm.h
+++ b/colm/colm.h
@@ -8,11 +8,11 @@ extern "C" {
struct colm_tree;
struct colm_kid;
struct colm_program;
-struct colm_runtime_data;
+struct colm_sections;
struct colm_tree;
struct colm_location;
-struct colm_program *colm_new_program( struct colm_runtime_data *rtd, long debug_realm );
+struct colm_program *colm_new_program( struct colm_sections *rtd, long debug_realm );
void colm_run_program( struct colm_program *prg, int argc, const char **argv );
struct colm_tree *colm_run_func( struct colm_program *prg, int frame_id, const char **params, int param_count );
int colm_delete_program( struct colm_program *prg );
diff --git a/colm/loadcolm.cc b/colm/loadcolm.cc
index 2c21ac63..65c0ebfa 100644
--- a/colm/loadcolm.cc
+++ b/colm/loadcolm.cc
@@ -33,7 +33,7 @@
#include "if2.h"
#include "colm/colm.h"
-extern RuntimeData main_runtimeData;
+extern RuntimeData colm_object;
InputLoc::InputLoc( colm_location *pcloc )
{
@@ -635,7 +635,7 @@ struct LoadColm
argv[0] = file.data;
argv[1] = 0;
- colm_program *program = colm_new_program( &main_runtimeData, 0 );
+ colm_program *program = colm_new_program( &colm_object, 0 );
colm_run_program( program, 1, argv );
/* Extract the parse tree. */
@@ -1904,7 +1904,7 @@ void LoadColm::go( long activeRealm )
argv[0] = inputFileName;
argv[1] = 0;
- colm_program *program = colm_new_program( &main_runtimeData, activeRealm );
+ colm_program *program = colm_new_program( &colm_object, activeRealm );
colm_run_program( program, 1, argv );
/* Extract the parse tree. */
diff --git a/colm/loadinit.cc b/colm/loadinit.cc
index 794506eb..3a6a965e 100644
--- a/colm/loadinit.cc
+++ b/colm/loadinit.cc
@@ -36,7 +36,7 @@
using std::string;
-extern RuntimeData main_runtimeData;
+extern RuntimeData colm_object;
void LoadInit::walkProdElList( ProdElList *list, prod_el_list &prodElList )
{
@@ -338,7 +338,7 @@ void LoadInit::go( long activeRealm )
argv[0] = inputFileName;
argv[1] = 0;
- colm_program *program = colm_new_program( &main_runtimeData, 0 );
+ colm_program *program = colm_new_program( &colm_object, 0 );
colm_run_program( program, 1, argv );
/* Extract the parse tree. */
diff --git a/colm/pdacodegen.cc b/colm/pdacodegen.cc
index 29614388..469f95c0 100644
--- a/colm/pdacodegen.cc
+++ b/colm/pdacodegen.cc
@@ -66,7 +66,7 @@ void escapeLiteralString( std::ostream &out, const char *path )
void PdaCodeGen::defineRuntime()
{
out <<
- "extern RuntimeData main_runtimeData;\n"
+ "extern RuntimeData colm_program_text;\n"
"\n";
}
@@ -414,7 +414,7 @@ void PdaCodeGen::writeRuntimeData( RuntimeData *runtimeData, PdaTables *pdaTable
out << "};\n\n";
out <<
- "RuntimeData main_runtimeData = \n"
+ "RuntimeData colm_object = \n"
"{\n"
" " << lelInfo() << ",\n"
" " << runtimeData->numLangEls << ",\n"
diff --git a/colm/program.h b/colm/program.h
index a105d70b..225dc140 100644
--- a/colm/program.h
+++ b/colm/program.h
@@ -32,7 +32,7 @@ typedef struct ColmStackBlock
struct ColmStackBlock *next;
} StackBlock;
-typedef struct colm_runtime_data
+typedef struct colm_sections
{
LangElInfo *lelInfo;
long numLangEls;