summaryrefslogtreecommitdiff
path: root/cpp/src
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2016-01-20 10:36:51 +0100
committerJose <jose@zeroc.com>2016-01-20 10:36:51 +0100
commit13f4fd6d3cc5a044db66d9c25319419bb4ede5fa (patch)
treec230ae28caba40ac1f939fbedb5fd780d49fad0c /cpp/src
parentICE-6861 - removing public stream API (diff)
downloadice-13f4fd6d3cc5a044db66d9c25319419bb4ede5fa.tar.bz2
ice-13f4fd6d3cc5a044db66d9c25319419bb4ede5fa.tar.xz
ice-13f4fd6d3cc5a044db66d9c25319419bb4ede5fa.zip
ice_name/ice_id fixes & simplifications.
Diffstat (limited to 'cpp/src')
-rw-r--r--cpp/src/Glacier2Lib/Application.cpp6
-rw-r--r--cpp/src/Ice/Exception.cpp4
-rw-r--r--cpp/src/IceDB/IceDB.cpp30
-rw-r--r--cpp/src/IceDB/IceDB.h18
-rw-r--r--cpp/src/IceSSL/Certificate.cpp30
-rw-r--r--cpp/src/IceStorm/Parser.cpp9
-rw-r--r--cpp/src/IceUtil/CtrlCHandler.cpp13
-rw-r--r--cpp/src/IceUtil/Exception.cpp45
-rw-r--r--cpp/src/IceUtil/Options.cpp20
-rw-r--r--cpp/src/IceUtil/ThreadException.cpp48
-rw-r--r--cpp/src/IceXML/Parser.cpp10
-rw-r--r--cpp/src/Slice/FileTracker.cpp10
-rw-r--r--cpp/src/Slice/PythonUtil.cpp5
-rw-r--r--cpp/src/slice2cpp/Gen.cpp7
-rw-r--r--cpp/src/slice2cs/Gen.cpp9
-rw-r--r--cpp/src/slice2java/Gen.cpp10
-rw-r--r--cpp/src/slice2objc/Gen.cpp9
-rw-r--r--cpp/src/slice2php/Main.cpp11
18 files changed, 104 insertions, 190 deletions
diff --git a/cpp/src/Glacier2Lib/Application.cpp b/cpp/src/Glacier2Lib/Application.cpp
index b8edf35c07c..85b092978cf 100644
--- a/cpp/src/Glacier2Lib/Application.cpp
+++ b/cpp/src/Glacier2Lib/Application.cpp
@@ -45,16 +45,18 @@ private:
}
string
-Glacier2::RestartSessionException::ice_name() const
+Glacier2::RestartSessionException::ice_id() const
{
- return "RestartSessionException";
+ return "::Glacier2::RestartSessionException";
}
+#ifndef ICE_CPP11_MAPPING
Glacier2::RestartSessionException*
Glacier2::RestartSessionException::ice_clone() const
{
return new RestartSessionException(*this);
}
+#endif
void
Glacier2::RestartSessionException::ice_throw() const
diff --git a/cpp/src/Ice/Exception.cpp b/cpp/src/Ice/Exception.cpp
index 8377c6c2230..7114d693664 100644
--- a/cpp/src/Ice/Exception.cpp
+++ b/cpp/src/Ice/Exception.cpp
@@ -129,7 +129,7 @@ Ice::LocalException::LocalException(const char* file, int line) :
{
}
-Ice::LocalException::~LocalException() throw()
+Ice::LocalException::~LocalException() ICE_NOEXCEPT
{
}
@@ -138,7 +138,7 @@ Ice::SystemException::SystemException(const char* file, int line) :
{
}
-Ice::SystemException::~SystemException() throw()
+Ice::SystemException::~SystemException() ICE_NOEXCEPT
{
}
diff --git a/cpp/src/IceDB/IceDB.cpp b/cpp/src/IceDB/IceDB.cpp
index a679baa8819..48891521f5e 100644
--- a/cpp/src/IceDB/IceDB.cpp
+++ b/cpp/src/IceDB/IceDB.cpp
@@ -15,22 +15,20 @@
using namespace IceDB;
using namespace std;
-const char* IceDB::LMDBException::_name = "IceDB::LMDBException";
-
LMDBException::LMDBException(const char* file, int line, int err) :
IceUtil::Exception(file, line),
_error(err)
{
}
-LMDBException::~LMDBException() throw()
+LMDBException::~LMDBException() ICE_NOEXCEPT
{
}
string
-LMDBException::ice_name() const
+LMDBException::ice_id() const
{
- return _name;
+ return "::IceDB::LMDBException";
}
void
@@ -40,11 +38,13 @@ LMDBException::ice_print(ostream& out) const
out << ": " << mdb_strerror(_error);
}
+#ifndef ICE_CPP11_MAPPING
LMDBException*
LMDBException::ice_clone() const
{
return new LMDBException(*this);
}
+#endif
void
LMDBException::ice_throw() const
@@ -58,22 +58,20 @@ LMDBException::error() const
return _error;
}
-const char* IceDB::KeyTooLongException::_name = "IceDB::KeyTooLongException";
-
KeyTooLongException::KeyTooLongException(const char* file, int line, size_t size) :
IceUtil::Exception(file, line),
_size(size)
{
}
-KeyTooLongException::~KeyTooLongException() throw()
+KeyTooLongException::~KeyTooLongException() ICE_NOEXCEPT
{
}
string
-KeyTooLongException::ice_name() const
+KeyTooLongException::ice_id() const
{
- return _name;
+ return "::IceDB::KeyTooLongException";
}
void
@@ -88,11 +86,13 @@ KeyTooLongException::ice_print(ostream& out) const
out << "Max size = " << maxKeySize;
}
+#ifndef ICE_CPP11_MAPPING
KeyTooLongException*
KeyTooLongException::ice_clone() const
{
return new KeyTooLongException(*this);
}
+#endif
void
KeyTooLongException::ice_throw() const
@@ -100,22 +100,20 @@ KeyTooLongException::ice_throw() const
throw *this;
}
-const char* IceDB::BadEnvException::_name = "IceDB::BadEnvException";
-
BadEnvException::BadEnvException(const char* file, int line, size_t size) :
IceUtil::Exception(file, line),
_size(size)
{
}
-BadEnvException::~BadEnvException() throw()
+BadEnvException::~BadEnvException() ICE_NOEXCEPT
{
}
string
-BadEnvException::ice_name() const
+BadEnvException::ice_id() const
{
- return _name;
+ return "::IceDB::BadEnvException";
}
void
@@ -126,11 +124,13 @@ BadEnvException::ice_print(ostream& out) const
out << ", IceDB max key size = " << maxKeySize;
}
+#ifndef ICE_CPP11_MAPPING
BadEnvException*
BadEnvException::ice_clone() const
{
return new BadEnvException(*this);
}
+#endif
void
BadEnvException::ice_throw() const
diff --git a/cpp/src/IceDB/IceDB.h b/cpp/src/IceDB/IceDB.h
index 56a36f9249d..16a60a4afee 100644
--- a/cpp/src/IceDB/IceDB.h
+++ b/cpp/src/IceDB/IceDB.h
@@ -58,11 +58,13 @@ class ICE_DB_API LMDBException : public IceUtil::Exception
public:
LMDBException(const char*, int, int);
- virtual ~LMDBException() throw();
+ virtual ~LMDBException() ICE_NOEXCEPT;
- virtual std::string ice_name() const;
+ virtual std::string ice_id() const;
virtual void ice_print(std::ostream&) const;
+#ifndef ICE_CPP11_MAPPING
virtual LMDBException* ice_clone() const;
+#endif
virtual void ice_throw() const;
int error() const;
@@ -82,11 +84,13 @@ class ICE_DB_API KeyTooLongException : public IceUtil::Exception
public:
KeyTooLongException(const char*, int, size_t);
- virtual ~KeyTooLongException() throw();
+ virtual ~KeyTooLongException() ICE_NOEXCEPT;
- virtual std::string ice_name() const;
+ virtual std::string ice_id() const;
virtual void ice_print(std::ostream&) const;
+#ifndef ICE_CPP11_MAPPING
virtual KeyTooLongException* ice_clone() const;
+#endif
virtual void ice_throw() const;
private:
@@ -104,11 +108,13 @@ class ICE_DB_API BadEnvException : public IceUtil::Exception
public:
BadEnvException(const char*, int, size_t);
- virtual ~BadEnvException() throw();
+ virtual ~BadEnvException() ICE_NOEXCEPT;
- virtual std::string ice_name() const;
+ virtual std::string ice_id() const;
virtual void ice_print(std::ostream&) const;
+#ifndef ICE_CPP11_MAPPING
virtual BadEnvException* ice_clone() const;
+#endif
virtual void ice_throw() const;
private:
diff --git a/cpp/src/IceSSL/Certificate.cpp b/cpp/src/IceSSL/Certificate.cpp
index ee814eb420f..6ddde411ddb 100644
--- a/cpp/src/IceSSL/Certificate.cpp
+++ b/cpp/src/IceSSL/Certificate.cpp
@@ -47,8 +47,6 @@ using namespace std;
using namespace Ice;
using namespace IceSSL;
-const char* IceSSL::CertificateReadException::_name = "IceSSL::CertificateReadException";
-
#if defined(ICE_USE_SECURE_TRANSPORT) || defined(ICE_USE_SCHANNEL)
//
// Map a certificate OID to its alias
@@ -429,21 +427,23 @@ CertificateReadException::CertificateReadException(const char* file, int line, c
{
}
-CertificateReadException::~CertificateReadException() throw()
+CertificateReadException::~CertificateReadException() ICE_NOEXCEPT
{
}
string
-CertificateReadException::ice_name() const
+CertificateReadException::ice_id() const
{
- return _name;
+ return "::IceSSL::CertificateReadException";
}
+#ifndef ICE_CPP11_MAPPING
CertificateReadException*
CertificateReadException::ice_clone() const
{
return new CertificateReadException(*this);
}
+#endif
void
CertificateReadException::ice_throw() const
@@ -451,8 +451,6 @@ CertificateReadException::ice_throw() const
throw *this;
}
-const char* IceSSL::CertificateEncodingException::_name = "IceSSL::CertificateEncodingException";
-
#ifdef ICE_USE_SECURE_TRANSPORT
CertificateEncodingException::CertificateEncodingException(const char* file, int line, CFErrorRef err) :
Exception(file, line)
@@ -469,21 +467,23 @@ CertificateEncodingException::CertificateEncodingException(const char* file, int
{
}
-CertificateEncodingException::~CertificateEncodingException() throw()
+CertificateEncodingException::~CertificateEncodingException() ICE_NOEXCEPT
{
}
string
-CertificateEncodingException::ice_name() const
+CertificateEncodingException::ice_id() const
{
- return _name;
+ return "::IceSSL::CertificateEncodingException";
}
+#ifndef ICE_CPP11_MAPPING
CertificateEncodingException*
CertificateEncodingException::ice_clone() const
{
return new CertificateEncodingException(*this);
}
+#endif
void
CertificateEncodingException::ice_throw() const
@@ -663,29 +663,29 @@ convertGeneralNames(GENERAL_NAMES* gens)
}
#endif
-const char* ParseException::_name = "IceSSL::ParseException";
-
ParseException::ParseException(const char* file, int line, const string& r) :
Exception(file, line),
reason(r)
{
}
-ParseException::~ParseException() throw()
+ParseException::~ParseException() ICE_NOEXCEPT
{
}
string
-ParseException::ice_name() const
+ParseException::ice_id() const
{
- return _name;
+ return "::IceSSL::ParseException";
}
+#ifndef ICE_CPP11_MAPPING
ParseException*
ParseException::ice_clone() const
{
return new ParseException(*this);
}
+#endif
void
ParseException::ice_throw() const
diff --git a/cpp/src/IceStorm/Parser.cpp b/cpp/src/IceStorm/Parser.cpp
index ce7b7bf95bc..8957864f8dc 100644
--- a/cpp/src/IceStorm/Parser.cpp
+++ b/cpp/src/IceStorm/Parser.cpp
@@ -46,13 +46,14 @@ public:
}
virtual
- ~UnknownManagerException() throw()
+ ~UnknownManagerException() ICE_NOEXCEPT
{
}
+
virtual string
- ice_name() const
+ ice_id() const
{
- return "UnknownManagerException";
+ return "::UnknownManagerException";
}
virtual Exception*
@@ -334,7 +335,7 @@ Parser::replica(const list<string>& args)
}
catch(const Exception& ex)
{
- cout << p->id << ": " << ex.ice_name() << endl;
+ cout << p->id << ": " << ex.ice_id() << endl;
}
}
}
diff --git a/cpp/src/IceUtil/CtrlCHandler.cpp b/cpp/src/IceUtil/CtrlCHandler.cpp
index f21281f8a0d..3e0633172d6 100644
--- a/cpp/src/IceUtil/CtrlCHandler.cpp
+++ b/cpp/src/IceUtil/CtrlCHandler.cpp
@@ -55,24 +55,19 @@ CtrlCHandlerException::CtrlCHandlerException(const char* file, int line) :
{
}
-namespace
-{
-
-const char* ctrlCHandlerName = "IceUtil::CtrlCHandlerException";
-
-}
-
string
-CtrlCHandlerException::ice_name() const
+CtrlCHandlerException::ice_id() const
{
- return ctrlCHandlerName;
+ return "::IceUtil::CtrlCHandlerException";
}
+#ifndef ICE_CPP11_MAPPING
CtrlCHandlerException*
CtrlCHandlerException::ice_clone() const
{
return new CtrlCHandlerException(*this);
}
+#endif
void
CtrlCHandlerException::ice_throw() const
diff --git a/cpp/src/IceUtil/Exception.cpp b/cpp/src/IceUtil/Exception.cpp
index eab14ddffa1..46a6de3749e 100644
--- a/cpp/src/IceUtil/Exception.cpp
+++ b/cpp/src/IceUtil/Exception.cpp
@@ -468,7 +468,7 @@ IceUtil::Exception::ice_clone() const
string
IceUtil::Exception::ice_name() const
{
- return "IceUtil::Exception";
+ return ice_id().substr(2);
}
IceUtil::Exception*
@@ -529,12 +529,6 @@ IceUtil::NullHandleException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::NullHandleException::ice_name() const
-{
- return "IceUtil::NullHandleException";
-}
-
IceUtil::NullHandleException*
IceUtil::NullHandleException::ice_clone() const
{
@@ -577,12 +571,6 @@ IceUtil::IllegalArgumentException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::IllegalArgumentException::ice_name() const
-{
- return "IceUtil::IllegalArgumentException";
-}
-
IceUtil::IllegalArgumentException*
IceUtil::IllegalArgumentException::ice_clone() const
{
@@ -633,12 +621,6 @@ IceUtil::IllegalConversionException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::IllegalConversionException::ice_name() const
-{
- return "IceUtil::IllegalConversionException";
-}
-
IceUtil::IllegalConversionException*
IceUtil::IllegalConversionException::ice_clone() const
{
@@ -683,13 +665,6 @@ IceUtil::SyscallException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-
-string
-IceUtil::SyscallException::ice_name() const
-{
- return "IceUtil::SyscallException";
-}
-
IceUtil::SyscallException*
IceUtil::SyscallException::ice_clone() const
{
@@ -739,12 +714,6 @@ IceUtil::FileLockException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::FileLockException::ice_name() const
-{
- return "IceUtil::FileLockException";
-}
-
IceUtil::FileLockException*
IceUtil::FileLockException::ice_clone() const
{
@@ -784,12 +753,6 @@ IceUtil::OptionalNotSetException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::OptionalNotSetException::ice_name() const
-{
- return "IceUtil::OptionalNotSetException";
-}
-
IceUtil::OptionalNotSetException*
IceUtil::OptionalNotSetException::ice_clone() const
{
@@ -828,12 +791,6 @@ IceUtil::IconvInitializationException::ice_id() const
}
#ifndef ICE_CPP11_MAPPING
-string
-IceUtil::IconvInitializationException::ice_name() const
-{
- return "IceUtil::IconvInitializationException";
-}
-
IceUtil::IconvInitializationException*
IceUtil::IconvInitializationException::ice_clone() const
{
diff --git a/cpp/src/IceUtil/Options.cpp b/cpp/src/IceUtil/Options.cpp
index a2201deed1f..309a5303a64 100644
--- a/cpp/src/IceUtil/Options.cpp
+++ b/cpp/src/IceUtil/Options.cpp
@@ -20,16 +20,14 @@ IceUtilInternal::APIException::APIException(const char* file, int line, const st
{
}
-IceUtilInternal::APIException::~APIException() throw()
+IceUtilInternal::APIException::~APIException() ICE_NOEXCEPT
{
}
-const char* IceUtilInternal::APIException::_name = "IceUtilInternal::APIException";
-
string
-IceUtilInternal::APIException::ice_name() const
+IceUtilInternal::APIException::ice_id() const
{
- return _name;
+ return "::IceUtilInternal::APIException";
}
void
@@ -42,11 +40,13 @@ IceUtilInternal::APIException::ice_print(ostream& out) const
}
}
+#ifndef ICE_CPP11_MAPPING
IceUtilInternal::APIException*
IceUtilInternal::APIException::ice_clone() const
{
return new APIException(*this);
}
+#endif
void
IceUtilInternal::APIException::ice_throw() const
@@ -66,16 +66,14 @@ IceUtilInternal::BadOptException::BadOptException(const char* file, int line, co
{
}
-IceUtilInternal::BadOptException::~BadOptException() throw()
+IceUtilInternal::BadOptException::~BadOptException() ICE_NOEXCEPT
{
}
-const char* IceUtilInternal::BadOptException::_name = "IceUtilInternal::BadOptException";
-
string
-IceUtilInternal::BadOptException::ice_name() const
+IceUtilInternal::BadOptException::ice_id() const
{
- return _name;
+ return "::IceUtilInternal::BadOptException";
}
void
@@ -88,11 +86,13 @@ IceUtilInternal::BadOptException::ice_print(ostream& out) const
}
}
+#ifndef ICE_CPP11_MAPPING
IceUtilInternal::BadOptException*
IceUtilInternal::BadOptException::ice_clone() const
{
return new BadOptException(*this);
}
+#endif
void
IceUtilInternal::BadOptException::ice_throw() const
diff --git a/cpp/src/IceUtil/ThreadException.cpp b/cpp/src/IceUtil/ThreadException.cpp
index 4ab221e8a03..8b1e1a450a2 100644
--- a/cpp/src/IceUtil/ThreadException.cpp
+++ b/cpp/src/IceUtil/ThreadException.cpp
@@ -15,20 +15,20 @@ IceUtil::ThreadSyscallException::ThreadSyscallException(const char* file, int li
SyscallException(file, line, err)
{
}
-
-const char* IceUtil::ThreadSyscallException::_name = "IceUtil::ThreadSyscallException";
string
-IceUtil::ThreadSyscallException::ice_name() const
+IceUtil::ThreadSyscallException::ice_id() const
{
- return _name;
+ return "::IceUtil::ThreadSyscallException";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::ThreadSyscallException*
IceUtil::ThreadSyscallException::ice_clone() const
{
return new ThreadSyscallException(*this);
}
+#endif
void
IceUtil::ThreadSyscallException::ice_throw() const
@@ -41,19 +41,19 @@ IceUtil::ThreadLockedException::ThreadLockedException(const char* file, int line
{
}
-const char* IceUtil::ThreadLockedException::_name = "IceUtil::ThreadLockedException";
-
string
-IceUtil::ThreadLockedException::ice_name() const
+IceUtil::ThreadLockedException::ice_id() const
{
- return _name;
+ return "::IceUtil::ThreadLockedException";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::ThreadLockedException*
IceUtil::ThreadLockedException::ice_clone() const
{
return new ThreadLockedException(*this);
}
+#endif
void
IceUtil::ThreadLockedException::ice_throw() const
@@ -66,19 +66,19 @@ IceUtil::ThreadStartedException::ThreadStartedException(const char* file, int li
{
}
-const char* IceUtil::ThreadStartedException::_name = "IceUtil::ThreadStartedException";
-
string
-IceUtil::ThreadStartedException::ice_name() const
+IceUtil::ThreadStartedException::ice_id() const
{
- return _name;
+ return "::IceUtil::ThreadStartedException";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::ThreadStartedException*
IceUtil::ThreadStartedException::ice_clone() const
{
return new ThreadStartedException(*this);
}
+#endif
void
IceUtil::ThreadStartedException::ice_throw() const
@@ -91,19 +91,19 @@ IceUtil::ThreadNotStartedException::ThreadNotStartedException(const char* file,
{
}
-const char* IceUtil::ThreadNotStartedException::_name = "IceUtil::ThreadNotStartedException";
-
string
-IceUtil::ThreadNotStartedException::ice_name() const
+IceUtil::ThreadNotStartedException::ice_id() const
{
- return _name;
+ return "::IceUtil::ThreadNotStartedException";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::ThreadNotStartedException*
IceUtil::ThreadNotStartedException::ice_clone() const
{
return new ThreadNotStartedException(*this);
}
+#endif
void
IceUtil::ThreadNotStartedException::ice_throw() const
@@ -117,19 +117,19 @@ IceUtil::BadThreadControlException::BadThreadControlException(const char* file,
{
}
-const char* IceUtil::BadThreadControlException::_name = "IceUtil::BadThreadControlException";
-
string
-IceUtil::BadThreadControlException::ice_name() const
+IceUtil::BadThreadControlException::ice_id() const
{
- return _name;
+ return "::IceUtil::BadThreadControlException";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::BadThreadControlException*
IceUtil::BadThreadControlException::ice_clone() const
{
return new BadThreadControlException(*this);
}
+#endif
void
IceUtil::BadThreadControlException::ice_throw() const
@@ -143,13 +143,11 @@ IceUtil::InvalidTimeoutException::InvalidTimeoutException(const char* file, int
_timeout(timeout)
{
}
-
-const char* IceUtil::InvalidTimeoutException::_name = "IceUtil::InvalidTimeoutException";
string
-IceUtil::InvalidTimeoutException::ice_name() const
+IceUtil::InvalidTimeoutException::ice_id() const
{
- return _name;
+ return "::IceUtil::InvalidTimeoutException";
}
void
@@ -159,11 +157,13 @@ IceUtil::InvalidTimeoutException::ice_print(ostream& os) const
os << ":\ninvalid timeout: " << _timeout << " seconds";
}
+#ifndef ICE_CPP11_MAPPING
IceUtil::InvalidTimeoutException*
IceUtil::InvalidTimeoutException::ice_clone() const
{
return new InvalidTimeoutException(*this);
}
+#endif
void
IceUtil::InvalidTimeoutException::ice_throw() const
diff --git a/cpp/src/IceXML/Parser.cpp b/cpp/src/IceXML/Parser.cpp
index 9a32636b47e..cdcf553a8c5 100644
--- a/cpp/src/IceXML/Parser.cpp
+++ b/cpp/src/IceXML/Parser.cpp
@@ -28,16 +28,14 @@ IceXML::ParserException::ParserException(const char* file, int line, const strin
{
}
-IceXML::ParserException::~ParserException() throw()
+IceXML::ParserException::~ParserException() ICE_NOEXCEPT
{
}
-const char* IceXML::ParserException::_name = "IceXML::ParserException";
-
string
-IceXML::ParserException::ice_name() const
+IceXML::ParserException::ice_id() const
{
- return _name;
+ return "::IceXML::ParserException";
}
void
@@ -54,11 +52,13 @@ IceXML::ParserException::ice_print(std::ostream& out) const
}
}
+#ifndef ICE_CPP11_MAPPING
IceXML::ParserException*
IceXML::ParserException::ice_clone() const
{
return new ParserException(*this);
}
+#endif
void
IceXML::ParserException::ice_throw() const
diff --git a/cpp/src/Slice/FileTracker.cpp b/cpp/src/Slice/FileTracker.cpp
index fcf5060af5b..9b9149970e4 100644
--- a/cpp/src/Slice/FileTracker.cpp
+++ b/cpp/src/Slice/FileTracker.cpp
@@ -23,16 +23,14 @@ Slice::FileException::FileException(const char* file, int line, const string& r)
{
}
-Slice::FileException::~FileException() throw()
+Slice::FileException::~FileException() ICE_NOEXCEPT
{
}
-const char* Slice::FileException::_name = "Slice::FileException";
-
string
-Slice::FileException::ice_name() const
+Slice::FileException::ice_id() const
{
- return _name;
+ return "::Slice::FileException";
}
void
@@ -42,11 +40,13 @@ Slice::FileException::ice_print(ostream& out) const
out << ": " << _reason;
}
+#ifndef ICE_CPP11_MAPPING
Slice::FileException*
Slice::FileException::ice_clone() const
{
return new FileException(*this);
}
+#endif
void
Slice::FileException::ice_throw() const
diff --git a/cpp/src/Slice/PythonUtil.cpp b/cpp/src/Slice/PythonUtil.cpp
index f5aa79cd100..f28a565a53c 100644
--- a/cpp/src/Slice/PythonUtil.cpp
+++ b/cpp/src/Slice/PythonUtil.cpp
@@ -1084,11 +1084,6 @@ Slice::Python::CodeVisitor::visitExceptionStart(const ExceptionPtr& p)
_out << nl << "return IcePy.stringifyException(self)";
_out.dec();
_out << sp << nl << "__repr__ = __str__";
-
- //
- // _ice_name
- //
- _out << sp << nl << "_ice_name = '" << scoped.substr(2) << "'";
//
// _ice_id
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp
index bdc5e986be7..c496fec26e4 100644
--- a/cpp/src/slice2cpp/Gen.cpp
+++ b/cpp/src/slice2cpp/Gen.cpp
@@ -982,13 +982,6 @@ Slice::Gen::TypesVisitor::visitExceptionStart(const ExceptionPtr& p)
C << scoped.substr(2) << "::~" << name << "() throw()";
C << sb;
C << eb;
-
- H << nl << "ICE_DEPRECATED_API(\"ice_name() is deprecated, use ice_id() instead.\")";
- H << nl << "virtual ::std::string ice_name() const;";
- C << sp << nl << "::std::string" << nl << scoped.substr(2) << "::ice_name() const";
- C << sb;
- C << nl << "return \"" << p->scoped().substr(2) << "\";";
- C << eb;
H << nl << "virtual ::std::string ice_id() const;";
C << sp << nl << "::std::string" << nl << scoped.substr(2) << "::ice_id() const";
diff --git a/cpp/src/slice2cs/Gen.cpp b/cpp/src/slice2cs/Gen.cpp
index 7c00c5afff0..cc588231114 100644
--- a/cpp/src/slice2cs/Gen.cpp
+++ b/cpp/src/slice2cs/Gen.cpp
@@ -3708,14 +3708,7 @@ Slice::Gen::TypesVisitor::visitExceptionEnd(const ExceptionPtr& p)
_out << sp << nl << "#endregion"; // Constructors
- _out << sp;
- emitGeneratedCodeAttribute();
- _out << nl << "[_System.Obsolete(\"ice_name() is deprecated, use ice_id() instead.\")]";
- _out << nl << "public override string ice_name()";
- _out << sb;
- _out << nl << "return \"" << p->scoped().substr(2) << "\";";
- _out << eb;
-
+ _out << sp;
emitGeneratedCodeAttribute();
_out << nl << "public override string ice_id()";
_out << sb;
diff --git a/cpp/src/slice2java/Gen.cpp b/cpp/src/slice2java/Gen.cpp
index e9da95c087c..8df6121d117 100644
--- a/cpp/src/slice2java/Gen.cpp
+++ b/cpp/src/slice2java/Gen.cpp
@@ -3653,16 +3653,6 @@ Slice::Gen::TypesVisitor::visitExceptionStart(const ExceptionPtr& p)
}
}
- out << sp;
- out << nl << "/**";
- out << nl << " * @deprecated ice_name() is deprecated, use ice_id() instead.";
- out << nl << " **/";
- out << nl << "@Deprecated";
- out << nl << "public String" << nl << "ice_name()";
- out << sb;
- out << nl << "return \"" << scoped.substr(2) << "\";";
- out << eb;
-
out << sp << nl << "public String" << nl << "ice_id()";
out << sb;
out << nl << "return \"" << scoped << "\";";
diff --git a/cpp/src/slice2objc/Gen.cpp b/cpp/src/slice2objc/Gen.cpp
index 6455d87a4ce..361a8924b46 100644
--- a/cpp/src/slice2objc/Gen.cpp
+++ b/cpp/src/slice2objc/Gen.cpp
@@ -1283,15 +1283,6 @@ Slice::Gen::TypesVisitor::visitExceptionEnd(const ExceptionPtr& p)
}
//
- // ice_name
- //
- _H << nl << "-(NSString *) ice_name;";
- _M << sp << nl << "-(NSString *) ice_name";
- _M << sb;
- _M << nl << "return @\"" << p->scoped().substr(2) << "\";";
- _M << eb;
-
- //
// ice_id
//
_H << nl << "-(NSString *) ice_id;";
diff --git a/cpp/src/slice2php/Main.cpp b/cpp/src/slice2php/Main.cpp
index 2e42bc8fb73..4163fc193c6 100644
--- a/cpp/src/slice2php/Main.cpp
+++ b/cpp/src/slice2php/Main.cpp
@@ -684,16 +684,7 @@ CodeVisitor::visitExceptionStart(const ExceptionPtr& p)
_out << eb;
//
- // ice_name
- //
- _out << sp << nl << "public function ice_name()";
- _out << sb;
- _out << nl << "trigger_error('ice_name() is deprecated use ice_id() instead.', E_DEPRECATED);";
- _out << nl << "return '" << scoped.substr(2) << "';";
- _out << eb;
-
- //
- // ice_name
+ // ice_id
//
_out << sp << nl << "public function ice_id()";
_out << sb;