Mercurial > projects > orange
diff orange/serialization/SerializationException.d @ 9:99c52d46822a
Serialization works now with D2, deserialization still doesn't work
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Sat, 24 Jul 2010 18:58:18 +0200 |
parents | f7b078e85f7f |
children | 78e5fef4bbf2 |
line wrap: on
line diff
--- a/orange/serialization/SerializationException.d Wed Jul 21 13:44:08 2010 +0200 +++ b/orange/serialization/SerializationException.d Sat Jul 24 18:58:18 2010 +0200 @@ -8,7 +8,13 @@ import orange.util.string; -class SerializationException : Exception +version (Tango) + alias Exception ExceptionBase; + +else + alias Throwable ExceptionBase; + +class SerializationException : ExceptionBase { this (string message) { @@ -24,8 +30,19 @@ super(message); } - this (Exception exception) + version (Tango) { - super(exception.msg, exception.file, exception.line, exception.next, exception.info); + this (ExceptionBase exception) + { + super(exception.msg, exception.file, exception.line, exception.next, exception.info); + } + } + + else + { + this (ExceptionBase exception) + { + super(exception.msg, exception.file, exception.line); + } } } \ No newline at end of file