epoc32/include/stdapis/stlport/stdexcept
branchSymbian2
changeset 3 e1b950c65cb4
parent 2 2fe1408b6811
child 4 837f303aceeb
     1.1 --- a/epoc32/include/stdapis/stlport/stdexcept	Tue Mar 16 16:12:26 2010 +0000
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,290 +0,0 @@
     1.4 -/*
     1.5 - * © Portions copyright (c) 2006-2007 Nokia Corporation.  All rights reserved.
     1.6 - *
     1.7 - * Copyright (c) 1996,1997
     1.8 - * Silicon Graphics Computer Systems, Inc.
     1.9 - *
    1.10 - * Copyright (c) 1999 
    1.11 - * Boris Fomitchev
    1.12 - *
    1.13 - * This material is provided "as is", with absolutely no warranty expressed
    1.14 - * or implied. Any use is at your own risk.
    1.15 - *
    1.16 - * Permission to use or copy this software for any purpose is hereby granted 
    1.17 - * without fee, provided the above notices are retained on all copies.
    1.18 - * Permission to modify the code and to distribute modified code is granted,
    1.19 - * provided the above notices are retained, and a notice that the code was
    1.20 - * modified is included with the above copyright notice.
    1.21 - *
    1.22 - */
    1.23 -
    1.24 -
    1.25 -# if !defined (_STLP_OUTERMOST_HEADER_ID)
    1.26 -#  define _STLP_OUTERMOST_HEADER_ID 0x63
    1.27 -#  include <stl/_prolog.h>
    1.28 -# elif (_STLP_OUTERMOST_HEADER_ID == 0x63) && ! defined (_STLP_DONT_POP_0x63)
    1.29 -#  define _STLP_DONT_POP_0x63
    1.30 -# endif
    1.31 -
    1.32 -#ifndef _STLP_STDEXCEPT
    1.33 -#define _STLP_STDEXCEPT 1
    1.34 -
    1.35 -# ifdef _STLP_PRAGMA_ONCE
    1.36 -#  pragma once
    1.37 -# endif
    1.38 -
    1.39 -#if defined (_STLP_USE_TRAP_LEAVE)
    1.40 -
    1.41 -enum {
    1.42 -  STDEX_bad_alloc			= -10000,
    1.43 -  STDEX_logic_error			= -10001,
    1.44 -  STDEX_runtime_error		= -10002,
    1.45 -  STDEX_domain_error		= -10003,
    1.46 -  STDEX_invalid_argument	= -10004,
    1.47 -  STDEX_length_error		= -10005,
    1.48 -  STDEX_out_of_range		= -10006,
    1.49 -  STDEX_range_error			= -10007,
    1.50 -  STDEX_overflow_error		= -10008,
    1.51 -  STDEX_underflow_error		= -10009
    1.52 -};
    1.53 -
    1.54 -// User may override this
    1.55 -#ifndef STDEX_REPORT_EXCEPTION
    1.56 -# define STDEX_REPORT_EXCEPTION(x) 
    1.57 -#endif
    1.58 -
    1.59 -#endif
    1.60 -
    1.61 -# if !defined(_STLP_STDEXCEPT_SEEN) && \
    1.62 -   (!defined (_STLP_USE_NATIVE_STDEXCEPT) || defined (_STLP_USE_OWN_NAMESPACE))
    1.63 -
    1.64 -#  define _STLP_STDEXCEPT_SEEN 1
    1.65 -
    1.66 -#  include <exception>
    1.67 -
    1.68 -#if defined(_STLP_USE_EXCEPTIONS) || \
    1.69 -    !(defined(_MIPS_SIM) && defined(_ABIO32) && _MIPS_SIM == _ABIO32)
    1.70 -
    1.71 -# include <cstring>
    1.72 -
    1.73 -#ifndef _STLP_INTERNAL_ALLOC_H
    1.74 -# include <stl/_alloc.h>
    1.75 -#endif
    1.76 -
    1.77 -#ifndef _STLP_STRING_FWD_H
    1.78 -# include <stl/_string_fwd.h>
    1.79 -#endif
    1.80 -
    1.81 -# define _STLP_OWN_STDEXCEPT 1
    1.82 -
    1.83 -_STLP_BEGIN_NAMESPACE
    1.84 -
    1.85 -# if   ! defined (_STLP_NO_EXCEPTION_HEADER)
    1.86 -# if !defined(_STLP_EXCEPTION_BASE) && !defined(_STLP_BROKEN_EXCEPTION_CLASS) && defined (_STLP_USE_NAMESPACES) && defined (_STLP_USE_OWN_NAMESPACE)
    1.87 -using _STLP_VENDOR_EXCEPT_STD::exception;
    1.88 -# endif
    1.89 -# endif
    1.90 -#  define _STLP_EXCEPTION_BASE exception
    1.91 -
    1.92 -#ifdef __SYMBIAN32__
    1.93 -class __Named_exception : public _STLP_EXCEPTION_BASE {
    1.94 -#else
    1.95 -class _STLP_CLASS_DECLSPEC __Named_exception : public _STLP_EXCEPTION_BASE {
    1.96 -#endif //__SYMBIAN32__
    1.97 -public:
    1.98 -  _STLP_DECLSPEC __Named_exception(const string& __str) 
    1.99 -# ifdef _STLP_OWN_IOSTREAMS
   1.100 -    ;
   1.101 -  _STLP_DECLSPEC const char* what() const _STLP_NOTHROW_INHERENTLY;
   1.102 -  _STLP_DECLSPEC ~__Named_exception() _STLP_NOTHROW_INHERENTLY;
   1.103 -# else
   1.104 -  {
   1.105 -    strncpy(_M_name, __get_c_string(__str), _S_bufsize);
   1.106 -    _M_name[_S_bufsize - 1] = '\0';
   1.107 -  }
   1.108 -  const char* what() const _STLP_NOTHROW_INHERENTLY { return _M_name; }
   1.109 -# endif
   1.110 -
   1.111 -private:
   1.112 -  enum { _S_bufsize = 256 };
   1.113 -  char _M_name[_S_bufsize];
   1.114 -};
   1.115 -
   1.116 -#ifdef __SYMBIAN32__
   1.117 -class logic_error : public __Named_exception {
   1.118 -#else
   1.119 -class _STLP_CLASS_DECLSPEC logic_error : public __Named_exception {
   1.120 -#endif
   1.121 -public:
   1.122 -  _STLP_DECLSPEC logic_error(const string& __s)
   1.123 -#ifdef __SYMBIAN32__
   1.124 -    ;
   1.125 -#else
   1.126 -   : __Named_exception(__s) {}
   1.127 -#endif
   1.128 -# ifdef _STLP_OWN_IOSTREAMS
   1.129 -  _STLP_DECLSPEC ~logic_error() _STLP_NOTHROW_INHERENTLY;
   1.130 -# endif
   1.131 -};
   1.132 -
   1.133 -#ifdef __SYMBIAN32__
   1.134 -class runtime_error : public __Named_exception {
   1.135 -#else
   1.136 -class _STLP_CLASS_DECLSPEC runtime_error : public __Named_exception {
   1.137 -#endif
   1.138 -public:
   1.139 -  _STLP_DECLSPEC runtime_error(const string& __s)
   1.140 -#ifdef __SYMBIAN32__
   1.141 -    ;
   1.142 -#else
   1.143 -   : __Named_exception(__s) {}
   1.144 -#endif
   1.145 -# ifdef _STLP_OWN_IOSTREAMS
   1.146 -  _STLP_DECLSPEC ~runtime_error() _STLP_NOTHROW_INHERENTLY;
   1.147 -# endif
   1.148 -};
   1.149 -
   1.150 -#ifdef __SYMBIAN32__
   1.151 -class domain_error : public logic_error {
   1.152 -#else
   1.153 -class _STLP_CLASS_DECLSPEC domain_error : public logic_error {
   1.154 -#endif
   1.155 -public:
   1.156 -  _STLP_DECLSPEC domain_error(const string& __arg)
   1.157 -#ifdef __SYMBIAN32__
   1.158 -    ;
   1.159 -#else
   1.160 -   : logic_error(__arg) {}
   1.161 -#endif
   1.162 -# ifdef _STLP_OWN_IOSTREAMS
   1.163 -  _STLP_DECLSPEC ~domain_error() _STLP_NOTHROW_INHERENTLY;
   1.164 -# endif
   1.165 -};
   1.166 -
   1.167 -#ifdef __SYMBIAN32__
   1.168 -class invalid_argument : public logic_error {
   1.169 -#else
   1.170 -class _STLP_CLASS_DECLSPEC invalid_argument : public logic_error {
   1.171 -#endif
   1.172 -public:
   1.173 -  _STLP_DECLSPEC invalid_argument(const string& __arg)
   1.174 -#ifdef __SYMBIAN32__
   1.175 -    ;
   1.176 -#else
   1.177 -   : logic_error(__arg) {}
   1.178 -#endif
   1.179 -# ifdef _STLP_OWN_IOSTREAMS
   1.180 -  _STLP_DECLSPEC ~invalid_argument() _STLP_NOTHROW_INHERENTLY;
   1.181 -# endif
   1.182 -};
   1.183 -
   1.184 -#ifdef __SYMBIAN32__
   1.185 -class length_error : public logic_error {
   1.186 -#else
   1.187 -class _STLP_CLASS_DECLSPEC length_error : public logic_error {
   1.188 -#endif
   1.189 -public:
   1.190 -  _STLP_DECLSPEC length_error(const string& __arg)
   1.191 -#ifdef __SYMBIAN32__
   1.192 -    ;
   1.193 -#else
   1.194 -   : logic_error(__arg) {}
   1.195 -#endif
   1.196 -# ifdef _STLP_OWN_IOSTREAMS
   1.197 -  _STLP_DECLSPEC ~length_error() _STLP_NOTHROW_INHERENTLY;
   1.198 -# endif
   1.199 -};
   1.200 -
   1.201 -#ifdef __SYMBIAN32__
   1.202 -class out_of_range : public logic_error {
   1.203 -#else
   1.204 -class _STLP_CLASS_DECLSPEC out_of_range : public logic_error {
   1.205 -#endif
   1.206 -public:
   1.207 -  _STLP_DECLSPEC out_of_range(const string& __arg)
   1.208 -#ifdef __SYMBIAN32__
   1.209 -    ;
   1.210 -#else
   1.211 -   : logic_error(__arg) {}
   1.212 -#endif
   1.213 -# ifdef _STLP_OWN_IOSTREAMS
   1.214 -  _STLP_DECLSPEC ~out_of_range() _STLP_NOTHROW_INHERENTLY;
   1.215 -# endif
   1.216 -};
   1.217 -
   1.218 -#ifdef __SYMBIAN32__
   1.219 -class range_error : public runtime_error {
   1.220 -#else
   1.221 -class _STLP_CLASS_DECLSPEC range_error : public runtime_error {
   1.222 -#endif
   1.223 -public:
   1.224 -  _STLP_DECLSPEC range_error(const string& __arg)
   1.225 -#ifdef __SYMBIAN32__
   1.226 -    ;
   1.227 -#else
   1.228 -   : runtime_error(__arg) {}
   1.229 -#endif
   1.230 -# ifdef _STLP_OWN_IOSTREAMS
   1.231 -  _STLP_DECLSPEC ~range_error() _STLP_NOTHROW_INHERENTLY;
   1.232 -# endif
   1.233 -};
   1.234 -
   1.235 -#ifdef __SYMBIAN32__
   1.236 -class overflow_error : public runtime_error {
   1.237 -#else
   1.238 -class _STLP_CLASS_DECLSPEC overflow_error : public runtime_error {
   1.239 -#endif
   1.240 -public:
   1.241 -  _STLP_DECLSPEC overflow_error(const string& __arg)
   1.242 -#ifdef __SYMBIAN32__
   1.243 -    ;
   1.244 -#else
   1.245 -   : runtime_error(__arg) {}
   1.246 -#endif
   1.247 -# ifdef _STLP_OWN_IOSTREAMS
   1.248 -  _STLP_DECLSPEC ~overflow_error() _STLP_NOTHROW_INHERENTLY;
   1.249 -# endif
   1.250 -};
   1.251 -
   1.252 -#ifdef __SYMBIAN32__
   1.253 -class underflow_error : public runtime_error {
   1.254 -#else
   1.255 -class _STLP_CLASS_DECLSPEC underflow_error : public runtime_error {
   1.256 -#endif
   1.257 -public:
   1.258 -  _STLP_DECLSPEC underflow_error(const string& __arg)
   1.259 -#ifdef __SYMBIAN32__
   1.260 -    ;
   1.261 -#else
   1.262 -   : runtime_error(__arg) {}
   1.263 -#endif
   1.264 -# ifdef _STLP_OWN_IOSTREAMS
   1.265 -  _STLP_DECLSPEC ~underflow_error() _STLP_NOTHROW_INHERENTLY;
   1.266 -# endif
   1.267 -};
   1.268 -
   1.269 -_STLP_END_NAMESPACE
   1.270 -
   1.271 -#endif /* Not o32, and no exceptions */
   1.272 -# endif /* _STLP_STDEXCEPT_SEEN */
   1.273 -
   1.274 -
   1.275 -#if defined (_STLP_USE_NATIVE_STDEXCEPT)
   1.276 -#  include _STLP_NATIVE_HEADER(stdexcept)
   1.277 -# endif
   1.278 -
   1.279 -#endif /* _STLP_STDEXCEPT */
   1.280 -
   1.281 -# if (_STLP_OUTERMOST_HEADER_ID == 0x63)
   1.282 -#  if ! defined (_STLP_DONT_POP_0x63)
   1.283 -#   include <stl/_epilog.h>
   1.284 -#   undef  _STLP_OUTERMOST_HEADER_ID
   1.285 -#   endif
   1.286 -#   undef  _STLP_DONT_POP_0x63
   1.287 -# endif
   1.288 -
   1.289 -
   1.290 -// Local Variables:
   1.291 -// mode:C++
   1.292 -// End:
   1.293 -