diff options
Diffstat (limited to 'cpp/src/slice2cpp/Gen.cpp')
-rw-r--r-- | cpp/src/slice2cpp/Gen.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp index 06bec36200c..eda491f8fb6 100644 --- a/cpp/src/slice2cpp/Gen.cpp +++ b/cpp/src/slice2cpp/Gen.cpp @@ -199,6 +199,11 @@ Slice::Gen::generate(const UnitPtr& unit) H << "\n#include <Ice/LocalObject.h>"; } + if(unit->usesConsts()) + { + H << "\n#include <Ice/Const.h>"; + } + StringList includes = unit->includeFiles(); for(StringList::const_iterator q = includes.begin(); q != includes.end(); ++q) { @@ -214,8 +219,6 @@ Slice::Gen::generate(const UnitPtr& unit) _dllExport += " "; } - printDefInt64Macro(H); - ProxyDeclVisitor proxyDeclVisitor(H, C, _dllExport); unit->visit(&proxyDeclVisitor); @@ -265,8 +268,6 @@ Slice::Gen::generate(const UnitPtr& unit) ImplVisitor implVisitor(implH, implC, _dllExport); unit->visit(&implVisitor); } - - printUndefInt64Macro(H); } Slice::Gen::TypesVisitor::TypesVisitor(Output& h, Output& c, const string& dllExport) : @@ -983,7 +984,7 @@ Slice::Gen::TypesVisitor::visitConstDef(const ConstDefPtr& p) } else if(bp && bp->kind() == Builtin::KindLong) { - H << "INT64LITERAL(" << p->value() << ")"; + H << "ICE_INT64_LITERAL(" << p->value() << ")"; } else { |