diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2017-09-03 14:38:03 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2017-09-03 14:38:03 +0100 |
commit | c52b9736009a510d7f195a28289f437c8155ad8c (patch) | |
tree | b914eb43604b21920f30ccef588a315c83701a50 | |
parent | Add [json] test cases for local class operations (diff) | |
download | slicer-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.cpp | 4 |
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); } |