summaryrefslogtreecommitdiff
path: root/cli/cli/source.cxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2022-06-30 14:25:16 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2022-06-30 16:29:57 +0300
commit1f83704a70b9c4065a5eb9f65e94919415d238ae (patch)
tree70d6fc1c1aeffe943e8fb4e48154b71da0d473a1 /cli/cli/source.cxx
parentbe64f285c1c74567353838f37203c63d3d8e27b5 (diff)
Add support for using bool with std::vector, std::set, and std::map
Diffstat (limited to 'cli/cli/source.cxx')
-rw-r--r--cli/cli/source.cxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/cli/cli/source.cxx b/cli/cli/source.cxx
index 1b9e832..3c04d1a 100644
--- a/cli/cli/source.cxx
+++ b/cli/cli/source.cxx
@@ -110,8 +110,12 @@ namespace
for (names::name_iterator i (n.name_begin ()); i != n.name_end (); ++i)
{
os << "_cli_" << scope << "_map_[\"" << *i << "\"] =" << endl
- << "&" << cli << "::thunk< " << scope << ", " << type << ", " <<
- "&" << scope << "::" << member;
+ << "&" << cli << "::thunk< " << scope;
+
+ if (type != "bool")
+ os << ", " << type;
+
+ os << ", " << "&" << scope << "::" << member;
if (gen_specifier && type != "bool")
os << "," << endl
@@ -1272,7 +1276,6 @@ generate_source (context& ctx)
ostream& os (ctx.os);
os << "#include <map>" << endl
- << "#include <cstring>" << endl
<< endl;
traversal::cli_unit unit;