Skip to content

Commit

Permalink
Merge pull request #40 from loverszhaokai/change_reference_to_pointer
Browse files Browse the repository at this point in the history
Change reference to pointer
  • Loading branch information
sparkprime committed Mar 2, 2015
2 parents 1903e5d + 18e5e6b commit 22f0bf3
Show file tree
Hide file tree
Showing 5 changed files with 81 additions and 81 deletions.
6 changes: 3 additions & 3 deletions libjsonnet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,20 +135,20 @@ static char *jsonnet_evaluate_snippet_aux(JsonnetVm *vm, const char *filename,
{
try {
Allocator alloc;
AST *expr = jsonnet_parse(alloc, filename, snippet);
AST *expr = jsonnet_parse(&alloc, filename, snippet);
std::string json_str;
std::map<std::string, std::string> files;
if (vm->debugAst) {
json_str = jsonnet_unparse_jsonnet(expr);
} else {
jsonnet_static_analysis(expr);
if (multi) {
files = jsonnet_vm_execute_multi(alloc, expr, vm->extVars, vm->maxStack,
files = jsonnet_vm_execute_multi(&alloc, expr, vm->extVars, vm->maxStack,
vm->gcMinObjects, vm->gcGrowthTrigger,
vm->importCallback, vm->importCallbackContext,
vm->stringOutput);
} else {
json_str = jsonnet_vm_execute(alloc, expr, vm->extVars, vm->maxStack,
json_str = jsonnet_vm_execute(&alloc, expr, vm->extVars, vm->maxStack,
vm->gcMinObjects, vm->gcGrowthTrigger,
vm->importCallback, vm->importCallbackContext,
vm->stringOutput);
Expand Down
Loading

0 comments on commit 22f0bf3

Please sign in to comment.