diff options
Diffstat (limited to 'cpp/src/Slice/CPlusPlusUtil.cpp')
-rw-r--r-- | cpp/src/Slice/CPlusPlusUtil.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/cpp/src/Slice/CPlusPlusUtil.cpp b/cpp/src/Slice/CPlusPlusUtil.cpp index 1de5af9b7fa..7a593a27706 100644 --- a/cpp/src/Slice/CPlusPlusUtil.cpp +++ b/cpp/src/Slice/CPlusPlusUtil.cpp @@ -1032,8 +1032,16 @@ Slice::writeMarshalUnmarshalCode(bool iceE, Output& out, const TypePtr& type, co if(dict) { string scope = fixKwd(dict->scope()); - out << nl << scope << "__" << func << (pointer ? "" : "&") << stream << ", " - << fixedParam << ", " << scope << "__U__" << fixKwd(dict->name()) << "());"; + if(iceE) + { + out << nl << scope << "__" << func << (pointer ? "" : "&") << stream << ", " + << fixedParam << ", " << scope << "__U__" << fixKwd(dict->name()) << "());"; + } + else + { + string funcDict = (marshal ? "write" : "read") + fixKwd(dict->name()) + "("; + out << nl << scope << "__" << funcDict << (pointer ? "" : "&") << stream << ", " << fixedParam << ");"; + } return; } |