diff options
author | John Wiegley <johnw@newartisans.com> | 2009-02-16 04:10:22 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-02-16 04:10:22 -0400 |
commit | 4365d9e3fcbe2546c15f188833a69cf8416f44fe (patch) | |
tree | 2f3da7ba36669752670a119983ef53f3eee02d40 /src/scope.cc | |
parent | aa69b273deda6cc29701fe9a4adf66abe8773cda (diff) | |
download | fork-ledger-4365d9e3fcbe2546c15f188833a69cf8416f44fe.tar.gz fork-ledger-4365d9e3fcbe2546c15f188833a69cf8416f44fe.tar.bz2 fork-ledger-4365d9e3fcbe2546c15f188833a69cf8416f44fe.zip |
Moved around some functions for clarity
Diffstat (limited to 'src/scope.cc')
-rw-r--r-- | src/scope.cc | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/scope.cc b/src/scope.cc index f4b2dfab..660f1af2 100644 --- a/src/scope.cc +++ b/src/scope.cc @@ -60,4 +60,21 @@ expr_t::ptr_op_t symbol_scope_t::lookup(const string& name) return child_scope_t::lookup(name); } +string join_args(call_scope_t& args) +{ + std::ostringstream buf; + bool first = true; + + for (std::size_t i = 0; i < args.size(); i++) { + if (first) { + buf << args[i]; + first = false; + } else { + buf << ' ' << args[i]; + } + } + + return buf.str(); +} + } // namespace ledger |