sc_iostream.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002 
00003   The following code is derived, directly or indirectly, from the SystemC
00004   source code Copyright (c) 1996-2005 by all Contributors.
00005   All Rights reserved.
00006 
00007   The contents of this file are subject to the restrictions and limitations
00008   set forth in the SystemC Open Source License Version 2.4 (the "License");
00009   You may not use this file except in compliance with such restrictions and
00010   limitations. You may obtain instructions on how to receive a copy of the
00011   License at http://www.systemc.org/. Software distributed by Contributors
00012   under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
00013   ANY KIND, either express or implied. See the License for the specific
00014   language governing rights and limitations under the License.
00015 
00016  *****************************************************************************/
00017 
00018 /*****************************************************************************
00019 
00020   sc_iostream.h - Portable iostream header file wrapper.
00021 
00022   Original Author: Martin Janssen, Synopsys, Inc.
00023 
00024  *****************************************************************************/
00025 
00026 /*****************************************************************************
00027 
00028   MODIFICATION LOG - modifiers, enter your name, affiliation, date and
00029   changes you are making here.
00030 
00031       Name, Affiliation, Date:
00032   Description of Modification:
00033 
00034  *****************************************************************************/
00035 
00036 #ifndef SC_IOSTREAM_H
00037 #define SC_IOSTREAM_H
00038 
00039 #if !defined( _MSC_VER ) &&  !defined( __BORLANDC__ )
00040 
00041 #   include <iostream>
00042 
00043 #   if defined(__GNUC__) && (__GNUC__ == 2) // Maintain compatibility for 2.95.x
00044 #       include <strstream>
00045 #   else
00046 #       include <sstream>
00047 #   endif
00048 
00049 #   include <fstream>
00050 #   include <cstddef>
00051 #   include <cstring>
00052 
00053 #else
00054 #if defined( _MSC_VER )
00055     // VC++6 with standard library
00056 
00057 #  include <iostream>
00058 #  include <strstream>
00059     
00060 #  include <fstream>
00061 
00062 #  include <cstddef>
00063 
00064 #else
00065 /*
00066 #if defined( __HP_aCC )
00067     // HP aCC
00068 
00069 #   include <iostream.h>
00070 #   include <strstream.h>
00071 #   include <fstream.h>
00072 
00073 #endif // HP
00074 */
00075 #endif // MSC
00076 #endif // Everyone else
00077 
00078 
00079 // shortcuts that save some typing
00080 
00081 #ifdef CCAST
00082 #    undef CCAST
00083 #endif
00084 #define CCAST       const_cast
00085 
00086 #ifdef DCAST
00087 #    undef DCAST
00088 #endif
00089 #define DCAST     dynamic_cast
00090 
00091 #ifdef RCAST
00092 #    undef RCAST
00093 #endif
00094 #define RCAST reinterpret_cast
00095 
00096 #ifdef SCAST
00097 #    undef SCAST
00098 #endif
00099 #define SCAST      static_cast
00100 
00101 #endif // !defined(SC_IOSTREAM_H)
Generated by
Matthieu Moy <Matthieu.Moy@st.com>
Back to Pinapa Home Page