summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2017-09-03 14:38:03 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2017-09-03 14:38:03 +0100
commitc52b9736009a510d7f195a28289f437c8155ad8c (patch)
treeb914eb43604b21920f30ccef588a315c83701a50
parentAdd [json] test cases for local class operations (diff)
downloadslicer-c52b9736009a510d7f195a28289f437c8155ad8c.tar.bz2
slicer-c52b9736009a510d7f195a28289f437c8155ad8c.tar.xz
slicer-c52b9736009a510d7f195a28289f437c8155ad8c.zip
tryConvert* should get the converstion function as a pointer
-rw-r--r--slicer/tool/parser.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/slicer/tool/parser.cpp b/slicer/tool/parser.cpp
index 8e37dfc..4458661 100644
--- a/slicer/tool/parser.cpp
+++ b/slicer/tool/parser.cpp
@@ -56,7 +56,7 @@ namespace Slicer {
fprintbf(cpp, "\tBOOST_ASSERT(Model);\n");
for (const auto & conversion : conversions) {
- fprintbf(cpp, "\tif (tryConvertFrom< %s >(vsp, Model, %s)) return;\n",
+ fprintbf(cpp, "\tif (tryConvertFrom< %s >(vsp, Model, &%s)) return;\n",
conversion.ExchangeType,
conversion.ConvertToModelFunc);
}
@@ -76,7 +76,7 @@ namespace Slicer {
fprintbf(cpp, "\tBOOST_ASSERT(Model);\n");
for (const auto & conversion : conversions) {
- fprintbf(cpp, "\tif (tryConvertTo< %s >(vtp, Model, %s)) return;\n",
+ fprintbf(cpp, "\tif (tryConvertTo< %s >(vtp, Model, &%s)) return;\n",
conversion.ExchangeType,
conversion.ConvertToExchangeFunc);
}