summaryrefslogtreecommitdiff
path: root/cpp/src/slice2cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/slice2cpp')
-rw-r--r--cpp/src/slice2cpp/Gen.cpp9
-rw-r--r--cpp/src/slice2cpp/Main.cpp3
-rw-r--r--cpp/src/slice2cpp/Makefile.mak4
3 files changed, 14 insertions, 2 deletions
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp
index 4c06ec03a98..b2a5b5384af 100644
--- a/cpp/src/slice2cpp/Gen.cpp
+++ b/cpp/src/slice2cpp/Gen.cpp
@@ -2367,6 +2367,15 @@ Slice::Gen::ProxyVisitor::visitOperation(const OperationPtr& p)
C << nl << "::IceInternal::Handle< ::IceDelegate::Ice::Object> __delBase;";
C << nl << "try";
C << sb;
+
+ C.zeroIndent();
+ C << nl << "#if defined(__BCPLUSPLUS__) && (__BCPLUSPLUS__ >= 0x0600) // C++Builder 2009 compiler bug";
+ C.restoreIndent();
+ C << nl << "IceUtil::DummyBCC dummy;";
+ C.zeroIndent();
+ C << nl << "#endif";
+ C.restoreIndent();
+
if(p->returnsData())
{
C << nl << "__checkTwowayOnly(" << p->flattenedScope() + p->name() + "_name);";
diff --git a/cpp/src/slice2cpp/Main.cpp b/cpp/src/slice2cpp/Main.cpp
index 7e42a5ab96a..cdbefe44792 100644
--- a/cpp/src/slice2cpp/Main.cpp
+++ b/cpp/src/slice2cpp/Main.cpp
@@ -85,6 +85,9 @@ main(int argc, char* argv[])
vector<string> args;
try
{
+#if defined(__BCPLUSPLUS__) && (__BCPLUSPLUS__ >= 0x0600)
+ IceUtil::DummyBCC dummy;
+#endif
args = opts.parse(argc, (const char**)argv);
}
catch(const IceUtilInternal::BadOptException& e)
diff --git a/cpp/src/slice2cpp/Makefile.mak b/cpp/src/slice2cpp/Makefile.mak
index 847211d4f52..e039744dea8 100644
--- a/cpp/src/slice2cpp/Makefile.mak
+++ b/cpp/src/slice2cpp/Makefile.mak
@@ -26,7 +26,7 @@ CPPFLAGS = -I. $(CPPFLAGS) -DWIN32_LEAN_AND_MEAN
PDBFLAGS = /pdb:$(NAME:.exe=.pdb)
!endif
-!if "$(CPP_COMPILER)" == "BCC2007"
+!if "$(BCPLUSPLUS)" == "yes"
RES_FILE = ,, Slice2Cpp.res
!else
RES_FILE = Slice2Cpp.res
@@ -46,7 +46,7 @@ install:: all
copy $(NAME) $(install_bindir)
-!if "$(CPP_COMPILER)" == "BCC2007" && "$(OPTIMIZE)" != "yes"
+!if "$(BCPLUSPLUS)" == "yes" && "$(OPTIMIZE)" != "yes"
install:: all
copy $(NAME:.exe=.tds) $(install_bindir)