summaryrefslogtreecommitdiff
path: root/tests/modulecachetest.cc
diff options
context:
space:
mode:
authorMarius Kintel <marius@kintel.net>2013-04-24 13:17:25 (GMT)
committerMarius Kintel <marius@kintel.net>2013-04-26 21:45:03 (GMT)
commit9b740b558dd627412e01a3521d5372d95e294af2 (patch)
treef34ebfa719303629e27d5fe84c177b5ac38adfbe /tests/modulecachetest.cc
parent9a297ecee57549a4eb3919bde4f7b41a548724de (diff)
Further refactoring of scope/context mechanisms. Mostly related to the new FileContext class. Not quite there yet, but almost
Diffstat (limited to 'tests/modulecachetest.cc')
-rw-r--r--tests/modulecachetest.cc11
1 files changed, 5 insertions, 6 deletions
diff --git a/tests/modulecachetest.cc b/tests/modulecachetest.cc
index fc9f325..5531461 100644
--- a/tests/modulecachetest.cc
+++ b/tests/modulecachetest.cc
@@ -76,14 +76,13 @@ int main(int argc, char **argv)
parser_init(boosty::stringy(fs::path(argv[0]).branch_path()));
add_librarydir(boosty::stringy(fs::path(argv[0]).branch_path() / "../libraries"));
- ModuleContext root_ctx;
- root_ctx.registerBuiltin();
+ ModuleContext top_ctx;
+ top_ctx.registerBuiltin();
- AbstractModule *root_module;
ModuleInstantiation root_inst("group");
AbstractNode *root_node;
- root_module = parsefile(filename);
+ FileModule *root_module = parsefile(filename);
if (!root_module) {
fprintf(stderr, "Error: Unable to parse input file\n");
exit(1);
@@ -94,7 +93,7 @@ int main(int argc, char **argv)
}
AbstractNode::resetIndexCounter();
- root_node = root_module->instantiate(&root_ctx, &root_inst);
+ root_node = root_module->instantiate(&top_ctx, &root_inst);
delete root_node;
delete root_module;
@@ -109,7 +108,7 @@ int main(int argc, char **argv)
}
AbstractNode::resetIndexCounter();
- root_node = root_module->instantiate(&root_ctx, &root_inst);
+ root_node = root_module->instantiate(&top_ctx, &root_inst);
delete root_node;
delete root_module;
contact: Jan Huwald // Impressum