Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Imported upstream version 1.9.86

Signed-off-by: Stefan Naewe <stefan.naewe@atlas-elektronik.com>
  • Loading branch information...
commit ce881e62d64a9f1c3267972bf510bbcef174c787 1 parent 2647deb
Stefan Naewe authored
Showing with 1,192 additions and 507 deletions.
  1. +78 −1 CHANGES.txt
  2. +10 −1 HISTORY.txt
  3. +3 −3 INSTALL.txt
  4. +3 −1 NEWS.txt
  5. +4 −4 include/acestl/acestl.hpp
  6. +4 −4 include/atlstl/atlstl.hpp
  7. +3 −3 include/comstl/comstl.h
  8. +4 −4 include/dotnetstl/dotnetstl.hpp
  9. +8 −7 include/inetstl/inetstl.h
  10. +4 −4 include/mfcstl/mfcstl.hpp
  11. +48 −11 include/platformstl/platformstl.h
  12. +3 −3 include/platformstl/platformstl.hpp
  13. +309 −4 include/stlsoft/functional/method_adaptors.hpp
  14. +9 −8 include/stlsoft/internal/cccap/borland.h
  15. +14 −8 include/stlsoft/internal/cccap/como.h
  16. +9 −8 include/stlsoft/internal/cccap/dmc.h
  17. +25 −21 include/stlsoft/internal/cccap/gcc.h
  18. +420 −239 include/stlsoft/internal/cccap/intel.h
  19. +87 −89 include/stlsoft/internal/cccap/msvc.h
  20. +10 −10 include/stlsoft/internal/cccap/mwerks.h
  21. +3 −3 include/stlsoft/internal/cccap/obsolete.h
  22. +6 −6 include/stlsoft/internal/cccap/sunpro.h
  23. +7 −7 include/stlsoft/internal/cccap/unknown.h
  24. +9 −8 include/stlsoft/internal/cccap/vectorc.h
  25. +5 −4 include/stlsoft/internal/cccap/watcom.h
  26. +30 −3 include/stlsoft/smartptr/scoped_handle_borland_.hpp
  27. +12 −11 include/stlsoft/stlsoft.h
  28. +30 −8 include/unixstl/error/exceptions.hpp
  29. +10 −3 include/unixstl/filesystem/filesystem_traits.hpp
  30. +4 −4 include/unixstl/unixstl.h
  31. +2 −2 include/winstl/error/error_desc.hpp
  32. +11 −7 include/winstl/filesystem/path.hpp
  33. +4 −4 include/winstl/winstl.h
  34. +4 −4 include/wtlstl/wtlstl.hpp
View
79 CHANGES.txt
@@ -2,7 +2,7 @@
STLSoft - Changes
; Created: 29th March 2002
-; Updated: 16th June 2009
+; Updated: 24th July 2009
============================================================================
@@ -19,6 +19,83 @@ STLSoft - Changes
============================================================================
+Changes for 1.9.86 (24th July 2009)
+
+Summary:
+========
+
+ * added STLSOFT_CF_THISCALL_SUPPORTED
+ * added thiscall overloads of mem_fun_ref() and mem_fun_ref_void()
+ * Borland compatibility for scoped_handle
+ * fix to unixstl::filesystem_traits::get_full_path_name() (to detect when path contains reserved characters)
+
+Changes:
+========
+
+ general:
+ =======
+
+ ~ include/acestl/acestl.hpp:
+ ~ include/atlstl/atlstl.hpp:
+ ~ include/comstl/comstl.h:
+ ~ include/dotnetstl/dotnetstl.hpp:
+ ~ include/inetstl/inetstl.h:
+ ~ include/mfcstl/mfcstl.hpp:
+ ~ include/unixstl/unixstl.h:
+ ~ include/winstl/error/error_desc.hpp:
+ ~ include/winstl/winstl.h:
+ ~ include/wtlstl/wtlstl.hpp:
+ ~ minor documentation change
+
+ STLSoft:
+ ========
+
+ ~ include/stlsoft/functional/method_adaptors.hpp:
+ ~ thiscall overloads of mem_fun_ref() and mem_fun_ref_void()
+
+ ~ include/stlsoft/internal/cccap/borland.h:
+ ~ include/stlsoft/internal/cccap/como.h:
+ ~ include/stlsoft/internal/cccap/dmc.h:
+ ~ include/stlsoft/internal/cccap/mwerks.h:
+ ~ include/stlsoft/internal/cccap/vectorc.h:
+ ~ include/stlsoft/internal/cccap/watcom.h:
+ + added compiler feature symbol STLSOFT_CF_THISCALL_SUPPORTED
+
+ ~ include/stlsoft/internal/cccap/gcc.h:
+ ~ include/stlsoft/internal/cccap/msvc.h:
+ + added compiler feature symbol STLSOFT_CF_THISCALL_SUPPORTED
+ ~ trivial formatting changes
+
+ ~ include/stlsoft/internal/cccap/intel.h:
+ + added compiler feature symbol STLSOFT_CF_THISCALL_SUPPORTED
+ ~ changed compiler discrimination features to STLSoft 1.10 mode
+
+ ~ include/stlsoft/smartptr/scoped_handle_borland_.hpp:
+ ~ Borland 5.5(.1) compatibility
+
+ PlatformSTL:
+ ============
+
+ ~ include/platformstl/platformstl.h:
+ + PlatformSTL contract enforcement macros
+
+ UNIXSTL:
+ ========
+
+ ~ include/unixstl/error/exceptions.hpp:
+ ~ suppresses "safe string" library warnings, when compiling with VC++
+
+ ~ include/unixstl/filesystem/filesystem_traits.hpp:
+ ~ get_full_path_name() now fails, and sets errno to ENOENT, if path contains a reserved character (one in "<>|*?")
+
+ WinSTL:
+ =======
+
+ ~ include/winstl/filesystem/path.hpp:
+ ~ minor changes to exception-specifications
+
+============================================================================
+
Changes for 1.9.85 (16th June 2009)
Summary:
View
11 HISTORY.txt
@@ -2,11 +2,20 @@
STLSoft - History
; Created: 29th March 2002
-; Updated: 16th June 2009
+; Updated: 24th July 2009
============================================================================
+24th July 2009 - 1.9.86 released
+--------------------------------
+
+ * added STLSOFT_CF_THISCALL_SUPPORTED
+ * added thiscall overloads of mem_fun_ref() and mem_fun_ref_void()
+ * Borland compatibility for scoped_handle
+ * fix to unixstl::filesystem_traits::get_full_path_name() (to detect when path contains reserved characters)
+
+
16th June 2009 - 1.9.85 released
--------------------------------
View
6 INSTALL.txt
@@ -2,15 +2,15 @@
STLSoft - Install
; Created: 29th March 2002
-; Updated: 16th June 2009
+; Updated: 24th July 2009
============================================================================
STLSoft is a 100% header-only library, and so requires no building.
It is recommended that you define an STLSOFT environment variable. For
- example, if you install to /usr/local/stlsoft/stlsoft-1.9.85, then you
- should set STLSOFT to /usr/local/stlsoft/stlsoft-1.9.85. In that case,
+ example, if you install to /usr/local/stlsoft/stlsoft-1.9.86, then you
+ should set STLSOFT to /usr/local/stlsoft/stlsoft-1.9.86. In that case,
the file stlsoft/stlsoft.h will be located in
$STLSOFT/include/stlsoft/stlsoft.h
View
4 NEWS.txt
@@ -2,13 +2,15 @@
STLSoft - News
; Created: 29th March 2002
-; Updated: 16th June 2009
+; Updated: 24th July 2009
============================================================================
News:
+ 24th July 2009 - Release of STLSoft 1.9.86
+
16th June 2009 - Release of STLSoft 1.9.85
23rd May 2009 - Release of STLSoft 1.9.84
View
8 include/acestl/acestl.hpp
@@ -5,11 +5,11 @@
* and platform discriminations, and definitions of types.
*
* Created: 15th September 2004
- * Updated: 9th October 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2004-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2004-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -47,7 +47,7 @@
# define ACESTL_VER_ACESTL_HPP_ACESTL_MAJOR 1
# define ACESTL_VER_ACESTL_HPP_ACESTL_MINOR 7
# define ACESTL_VER_ACESTL_HPP_ACESTL_REVISION 4
-# define ACESTL_VER_ACESTL_HPP_ACESTL_EDIT 38
+# define ACESTL_VER_ACESTL_HPP_ACESTL_EDIT 39
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file acestl/acestl.hpp
@@ -180,7 +180,7 @@
*/
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro acestl_assert provides standard debug-mode assert functionality.
*/
View
8 include/atlstl/atlstl.hpp
@@ -5,11 +5,11 @@
* and platform discriminations, and definitions of types.
*
* Created: 15th January 2002
- * Updated: 22nd September 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2002-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2002-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -48,7 +48,7 @@
# define ATLSTL_VER_ATLSTL_HPP_ATLSTL_MAJOR 3
# define ATLSTL_VER_ATLSTL_HPP_ATLSTL_MINOR 4
# define ATLSTL_VER_ATLSTL_HPP_ATLSTL_REVISION 3
-# define ATLSTL_VER_ATLSTL_HPP_ATLSTL_EDIT 103
+# define ATLSTL_VER_ATLSTL_HPP_ATLSTL_EDIT 104
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file atlstl/atlstl.hpp
@@ -226,7 +226,7 @@ extern CComModule _Module;
#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro atlstl_assert provides standard debug-mode assert functionality.
*/
View
6 include/comstl/comstl.h
@@ -5,7 +5,7 @@
* and platform discriminations, and definitions of types.
*
* Created: 15th January 2002
- * Updated: 22nd May 2009
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
@@ -53,7 +53,7 @@
# define COMSTL_VER_COMSTL_H_COMSTL_MAJOR 3
# define COMSTL_VER_COMSTL_H_COMSTL_MINOR 7
# define COMSTL_VER_COMSTL_H_COMSTL_REVISION 3
-# define COMSTL_VER_COMSTL_H_COMSTL_EDIT 110
+# define COMSTL_VER_COMSTL_H_COMSTL_EDIT 111
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file comstl/comstl.h
@@ -244,7 +244,7 @@
#endif /* compiler tag */
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro comstl_assert provides standard debug-mode assert functionality.
*/
View
8 include/dotnetstl/dotnetstl.hpp
@@ -5,11 +5,11 @@
* and platform discriminations, and definitions of types.
*
* Created: 12th May 2003
- * Updated: 9th March 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2003-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2003-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -48,7 +48,7 @@
# define DOTNETSTL_VER_DOTNETSTL_HPP_DOTNETSTL_MAJOR 3
# define DOTNETSTL_VER_DOTNETSTL_HPP_DOTNETSTL_MINOR 4
# define DOTNETSTL_VER_DOTNETSTL_HPP_DOTNETSTL_REVISION 2
-# define DOTNETSTL_VER_DOTNETSTL_HPP_DOTNETSTL_EDIT 48
+# define DOTNETSTL_VER_DOTNETSTL_HPP_DOTNETSTL_EDIT 49
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file dotnetstl/dotnetstl.hpp
@@ -180,7 +180,7 @@
//#endif /* _MSC_VER */
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro dotnetstl_assert provides standard debug-mode assert functionality.
*/
View
15 include/inetstl/inetstl.h
@@ -5,7 +5,7 @@
* and platform discriminations, and definitions of types.
*
* Created: 24th April 2004
- * Updated: 3rd May 2009
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
@@ -48,7 +48,7 @@
# define INETSTL_VER_INETSTL_H_INETSTL_MAJOR 3
# define INETSTL_VER_INETSTL_H_INETSTL_MINOR 5
# define INETSTL_VER_INETSTL_H_INETSTL_REVISION 2
-# define INETSTL_VER_INETSTL_H_INETSTL_EDIT 48
+# define INETSTL_VER_INETSTL_H_INETSTL_EDIT 49
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file inetstl/inetstl.h \brief [C, C++] The root header for the \ref group__project__inetstl "InetSTL" project. */
@@ -113,14 +113,15 @@
# define _INETSTL_VER_1_2_1 0x00010201 /*!< Version 1.2.1 (with STLSoft 1.9.1) */
# define _INETSTL_VER_1_2_2 0x00010202 /*!< Version 1.2.2 (with STLSoft 1.9.25) */
# define _INETSTL_VER_1_2_3 0x010203ff /*!< Version 1.2.3 (with STLSoft 1.9.46) */
-# define _INETSTL_VER_1_3_1 0x00010301 /*!< Version 1.3.1 (with STLSoft 1.9.79) */
-# define _INETSTL_VER_1_3_2 0x00010302 /*!< Version 1.3.2 (with STLSoft 1.9.80) */
+# define _INETSTL_VER_1_3_1 0x010301ff /*!< Version 1.3.1 (with STLSoft 1.9.79) */
+# define _INETSTL_VER_1_3_2 0x010302ff /*!< Version 1.3.2 (with STLSoft 1.9.80) */
+# define _INETSTL_VER_1_3_3 0x010303ff /*!< Version 1.3.3 (with STLSoft 1.9.86) */
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
#define _INETSTL_VER_MAJOR 1
#define _INETSTL_VER_MINOR 3
-#define _INETSTL_VER_REVISION 2
-#define _INETSTL_VER _INETSTL_VER_1_3_2
+#define _INETSTL_VER_REVISION 3
+#define _INETSTL_VER _INETSTL_VER_1_3_3
/* /////////////////////////////////////////////////////////////////////////
* Includes
@@ -251,7 +252,7 @@
#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro inetstl_assert provides standard debug-mode assert functionality.
*/
View
8 include/mfcstl/mfcstl.hpp
@@ -6,14 +6,14 @@
* types.
*
* Created: 15th January 2002
- * Updated: 22nd September 2008
+ * Updated: 21st July 2009
*
* Thanks: To Cláudio Albuquerque for suggesting the inclusion of
* atlstr.h.
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2002-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2002-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -52,7 +52,7 @@
# define MFCSTL_VER_MFCSTL_HPP_MFCSTL_MAJOR 3
# define MFCSTL_VER_MFCSTL_HPP_MFCSTL_MINOR 4
# define MFCSTL_VER_MFCSTL_HPP_MFCSTL_REVISION 3
-# define MFCSTL_VER_MFCSTL_HPP_MFCSTL_EDIT 90
+# define MFCSTL_VER_MFCSTL_HPP_MFCSTL_EDIT 91
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file mfcstl/mfcstl.hpp
@@ -225,7 +225,7 @@
#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
- * Debugging
+ * Contract Enforcement
*
* The macro mfcstl_assert provides standard debug-mode assert functionality.
*/
View
59 include/platformstl/platformstl.h
@@ -5,11 +5,11 @@
* platform discriminations, and definitions of types.
*
* Created: 20th March 2005
- * Updated: 13th December 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2005-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2005-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -46,9 +46,9 @@
/* File version */
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_MAJOR 1
-# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_MINOR 12
-# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_REVISION 3
-# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_EDIT 37
+# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_MINOR 13
+# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_REVISION 1
+# define PLATFORMSTL_VER_PLATFORMSTL_H_PLATFORMSTL_EDIT 38
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/** \file platformstl/platformstl.h
@@ -121,12 +121,13 @@
# define _PLATFORMSTL_VER_1_6_2 0x00010602 /*!< Version 1.6.2 (with STLSoft 1.9.25) */
# define _PLATFORMSTL_VER_1_7_1 0x00010701 /*!< Version 1.7.1 (with STLSoft 1.9.38) */
# define _PLATFORMSTL_VER_1_7_2 0x010702ff /*!< Version 1.7.2 (with STLSoft 1.9.64) */
+# define _PLATFORMSTL_VER_1_8_1 0x010801ff /*!< Version 1.8.1 (with STLSoft 1.9.86) */
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
#define _PLATFORMSTL_VER_MAJOR 1
-#define _PLATFORMSTL_VER_MINOR 7
-#define _PLATFORMSTL_VER_REVISION 2
-#define _PLATFORMSTL_VER _PLATFORMSTL_VER_1_7_2
+#define _PLATFORMSTL_VER_MINOR 8
+#define _PLATFORMSTL_VER_REVISION 1
+#define _PLATFORMSTL_VER _PLATFORMSTL_VER_1_8_1
/* /////////////////////////////////////////////////////////////////////////
* Includes
@@ -140,8 +141,8 @@
* STLSoft version compatibility
*/
-#if _STLSOFT_VER < 0x010926ff
-# error This version of the PlatformSTL libraries requires STLSoft version 1.9.38, or later. (www.stlsoft.org)
+#if _STLSOFT_VER < 0x010956ff
+# error This version of the PlatformSTL libraries requires STLSoft version 1.9.86, or later. (www.stlsoft.org)
#endif /* STLSoft version */
/* /////////////////////////////////////////////////////////////////////////
@@ -258,6 +259,42 @@
#endif /* operating system */
/* /////////////////////////////////////////////////////////////////////////
+ * Contract Enforcement
+ *
+ * The macro winstl_assert provides standard debug-mode assert functionality.
+ */
+
+/** \brief Defines an assertion construct for runtime verification.
+ *
+ * \param expr Must be non-zero, or an assertion will be fired
+ *
+ * \remarks By default this is defined to \ref STLSOFT_ASSERT. However, this
+ * can be overriden if a prior definition is encountered, allowing the
+ * runtime assertion of WinSTL components to use a different mechanism to
+ * those in the other \ref group__projects "projects".
+ */
+#ifndef PLATFORMSTL_ASSERT
+# define PLATFORMSTL_ASSERT(expr) STLSOFT_ASSERT(expr)
+#endif /* !PLATFORMSTL_ASSERT */
+
+/** \brief Defines a runtime assertion, with message
+ *
+ * \param expr Must be non-zero, or an assertion will be fired
+ * \param msg The literal character string message to be included in the assertion
+ */
+#define PLATFORMSTL_MESSAGE_ASSERT(msg, expr) STLSOFT_MESSAGE_ASSERT(msg, expr)
+
+/** \def PLATFORMSTL_STATIC_ASSERT(expr)
+ *
+ * \brief Defines an assertion construct for compile-time verification.
+ *
+ * \param expr A compile-time evaluatable condition that must be non-zero, or compilation will fail.
+ *
+ * \remarks This is defined to \ref STLSOFT_STATIC_ASSERT.
+ */
+#define PLATFORMSTL_STATIC_ASSERT(expr) STLSOFT_STATIC_ASSERT(expr)
+
+/* /////////////////////////////////////////////////////////////////////////
* Namespace
*
* The PLATFORMSTL components are contained within the platformstl namespace. This is
@@ -447,4 +484,4 @@ namespace platformstl = ::stlsoft::platformstl_project;
#endif /* !PLATFORMSTL_INCL_PLATFORMSTL_H_PLATFORMSTL */
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
6 include/platformstl/platformstl.hpp
@@ -5,11 +5,11 @@
* discriminations, and definitions of types.
*
* Created: 20th March 2005
- * Updated: 22nd September 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2005-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2005-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -110,4 +110,4 @@ namespace platformstl_project
#endif /* !PLATFORMSTL_INCL_PLATFORMSTL_HPP_PLATFORMSTL */
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
313 include/stlsoft/functional/method_adaptors.hpp
@@ -4,11 +4,11 @@
* Purpose: Contains the stlsoft::mem_fun calling convention-aware function adaptors.
*
* Created: 13th June 1999
- * Updated: 9th March 2008
+ * Updated: 8th June 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 1999-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 1999-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -52,8 +52,8 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_MAJOR 4
# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_MINOR 1
-# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_REVISION 2
-# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_EDIT 60
+# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_REVISION 3
+# define STLSOFT_VER_STLSOFT_FUNCTIONAL_HPP_METHOD_ADAPTORS_EDIT 61
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -99,6 +99,119 @@ namespace stlsoft
* Classes
*/
+// thiscall
+#ifdef STLSOFT_CF_THISCALL_SUPPORTED
+/** \brief A function class that invokes a <b>cdecl</b> calling convention
+ * 0-parameter mutating (non-const) member function on its pointer argument.
+ *
+ * \ingroup group__library__functional
+ */
+// [[synesis:class:function-class:unary-function: thiscall_mem_fun_t<T<R>, T<A>>]]
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+struct thiscall_mem_fun_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, R>
+{
+public:
+ typedef R return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)();
+public:
+ ss_explicit_k thiscall_mem_fun_t(method_type func)
+ : m_func(func)
+ {}
+ return_type operator ()(operand_class_type *pt) const
+ {
+ return (pt->*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+/** \brief A function class that invokes a <b>cdecl</b> calling convention
+ * 0-parameter non-mutating (const) member function on its pointer argument.
+ *
+ * \ingroup group__library__functional
+ */
+// [[synesis:class:function-class:unary-function: thiscall_mem_fun_t<T<R>, T<A>>]]
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+struct thiscall_mem_fun_const_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, R>
+{
+public:
+ typedef R return_type;
+ typedef T operand_class_type;
+# ifdef STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED
+ typedef return_type (T::*method_type)() const;
+# else /* ? STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED */
+ typedef return_type (T::*method_type)() const;
+# endif /* STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED */
+public:
+ ss_explicit_k thiscall_mem_fun_const_t(method_type func)
+ : m_func(func)
+ {}
+ return_type operator ()(operand_class_type const* pt) const
+ {
+ return (pt->*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+# ifndef STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID
+
+template< ss_typename_param_k T
+ >
+struct thiscall_mem_fun_void_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, void>
+{
+public:
+ typedef void return_type;
+ typedef T operand_class_type;
+# ifdef STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED
+ typedef return_type (T::*method_type)();
+# else /* ? STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED */
+ typedef return_type (T::*method_type)();
+# endif /* STLSOFT_CF_CALLING_CONVENTION_OUTSIDE_BRACE_REQUIRED */
+public:
+ ss_explicit_k thiscall_mem_fun_void_t(method_type func)
+ : m_func(func)
+ {}
+ void operator ()(operand_class_type *pt) const
+ {
+ (pt->*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+template< ss_typename_param_k T
+ >
+struct thiscall_mem_fun_const_void_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, void>
+{
+public:
+ typedef void return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)() const;
+public:
+ ss_explicit_k thiscall_mem_fun_const_void_t(method_type func)
+ : m_func(func)
+ {}
+ void operator ()(operand_class_type const* pt) const
+ {
+ (pt->*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+# endif /* STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+#endif /* STLSOFT_CF_THISCALL_SUPPORTED */
+
// cdecl
#ifdef STLSOFT_CF_CDECL_SUPPORTED
@@ -475,6 +588,111 @@ struct stdcall_mem_fun_const_void_t
+#ifdef STLSOFT_CF_THISCALL_SUPPORTED
+/** \brief A function class that invokes a <b>cdecl</b> calling convention
+ * 0-parameter mutating (non-const) member function on its pointer argument.
+ *
+ * \ingroup group__library__functional
+ */
+// [[synesis:class:function-class:unary-function: thiscall_mem_fun_ref_t<T<R>, T<A>>]]
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+struct thiscall_mem_fun_ref_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, R>
+{
+public:
+ typedef R return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)();
+public:
+ ss_explicit_k thiscall_mem_fun_ref_t(method_type func)
+ : m_func(func)
+ {}
+ return_type operator ()(operand_class_type& rt) const
+ {
+ return (rt.*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+/** \brief A function class that invokes a <b>thiscall</b> calling convention
+ * 0-parameter non-mutating (const) member function on its pointer argument.
+ *
+ * \ingroup group__library__functional
+ */
+// [[synesis:class:function-class:unary-function: thiscall_mem_fun_ref_t<T<R>, T<A>>]]
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+struct thiscall_mem_fun_ref_const_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, R>
+{
+public:
+ typedef R return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)() const;
+public:
+ ss_explicit_k thiscall_mem_fun_ref_const_t(method_type func)
+ : m_func(func)
+ {}
+ return_type operator ()(operand_class_type const& rt) const
+ {
+ return (rt.*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+# ifndef STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID
+
+template< ss_typename_param_k T
+ >
+struct thiscall_mem_fun_ref_void_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, void>
+{
+public:
+ typedef void return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)();
+public:
+ ss_explicit_k thiscall_mem_fun_ref_void_t(method_type func)
+ : m_func(func)
+ {}
+ void operator ()(operand_class_type& rt) const
+ {
+ (rt.*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+template< ss_typename_param_k T
+ >
+struct thiscall_mem_fun_ref_const_void_t
+ : public stlsoft_ns_qual_std(unary_function)<T*, void>
+{
+public:
+ typedef void return_type;
+ typedef T operand_class_type;
+ typedef return_type (T::*method_type)() const;
+public:
+ ss_explicit_k thiscall_mem_fun_ref_const_void_t(method_type func)
+ : m_func(func)
+ {}
+ void operator ()(operand_class_type const& rt) const
+ {
+ (rt.*m_func)();
+ }
+private:
+ method_type m_func;
+};
+
+# endif /* STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+#endif /* STLSOFT_CF_THISCALL_SUPPORTED */
+
+
#ifdef STLSOFT_CF_CDECL_SUPPORTED
@@ -1228,6 +1446,93 @@ inline stdcall_mem_fun_const_void_t<T> mem_fun_void(void (STLSOFT_STDCALL T::*fu
+#ifdef STLSOFT_CF_THISCALL_SUPPORTED
+
+/** \brief Creator function to adapt a pointer to a 0-parameter mutating
+ * (non-const) member function, for use with a reference to the class.
+ *
+ * \ingroup group__library__functional
+ */
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_t<R, T> mem_fun_ref(R (T::*func)())
+{
+ return thiscall_mem_fun_ref_t<R, T>(func);
+}
+
+#if defined(STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID)
+
+/* We just provide mem_fun_ref_void() that returns 'normal' type. */
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_t<void, T> mem_fun_ref_void(void (T::*func)())
+{
+ return thiscall_mem_fun_ref_t<void, T>(func);
+}
+
+#else /* ? STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_void_t<T> mem_fun_ref(void (T::*func)())
+{
+ return thiscall_mem_fun_ref_void_t<T>(func);
+}
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_void_t<T> mem_fun_ref_void(void (T::*func)())
+{
+ return thiscall_mem_fun_ref_void_t<T>(func);
+}
+
+#endif /* STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+
+
+/** \brief Creator function to adapt a pointer to a 0-parameter non-mutating
+ * (const) member function, for use with a reference to the class.
+ *
+ * \ingroup group__library__functional
+ */
+template< ss_typename_param_k R
+ , ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_const_t<R, T> mem_fun_ref(R (T::*func)() const)
+{
+ return thiscall_mem_fun_ref_const_t<R, T>(func);
+}
+
+#if defined(STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID)
+
+/* We just provide mem_fun_ref_void() that returns 'normal' type. */
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_const_t<void, T> mem_fun_ref_void(void (T::*func)() const)
+{
+ return thiscall_mem_fun_ref_const_t<void, T>(func);
+}
+
+#else /* ? STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_const_void_t<T> mem_fun_ref(void (T::*func)() const)
+{
+ return thiscall_mem_fun_ref_const_void_t<T>(func);
+}
+
+template< ss_typename_param_k T
+ >
+inline thiscall_mem_fun_ref_const_void_t<T> mem_fun_ref_void(void (T::*func)() const)
+{
+ return thiscall_mem_fun_ref_const_void_t<T>(func);
+}
+
+# endif /* STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID */
+#endif /* STLSOFT_CF_THISCALL_SUPPORTED */
// cdecl
#ifdef STLSOFT_CF_CDECL_SUPPORTED
View
17 include/stlsoft/internal/cccap/borland.h
@@ -4,7 +4,7 @@
* Purpose: Compiler feature discrimination for Borland C/C++.
*
* Created: 7th February 2003
- * Updated: 7th May 2009
+ * Updated: 21st July 2009
*
* Thanks to: markitus82 for pointing out overlooking of support for
* __FUNCTION__.
@@ -59,9 +59,9 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_MINOR 17
-# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_REVISION 2
-# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_EDIT 79
+# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_MINOR 18
+# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_REVISION 1
+# define STLSOFT_VER_H_STLSOFT_CCCAP_BORLAND_EDIT 82
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -339,15 +339,15 @@
* requires that you have defined _STLSOFT_CUSTOM_ASSERT() as a macro
* taking 1 parameter (the condition to assert).
*
- * Suppose you have a function _DisplayAssert(), which has the
+ * Suppose you have a function DisplayAssert_(), which has the
* following signature:
*
- * void _DisplayAssert(char const* file, int line, char const* expression);
+ * void DisplayAssert_(char const* file, int line, char const* expression);
*
* Presumably you would also have your own assert macro, say MY_ASSERT(),
* defined as:
*
- * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(_DisplayAssert(__FILE__, __LINE__, #_x))) : ((void)0)))
+ * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(DisplayAssert_(__FILE__, __LINE__, #_x))) : ((void)0)))
*
* so you would simply need to define _STLSOFT_CUSTOM_ASSERT() in terms of
* MY_ASSERT(), as in:
@@ -376,6 +376,7 @@
* Calling convention
*/
+#define STLSOFT_CF_THISCALL_SUPPORTED
#define STLSOFT_CF_CDECL_SUPPORTED
#define STLSOFT_CF_FASTCALL_SUPPORTED
#define STLSOFT_CF_STDCALL_SUPPORTED
@@ -429,4 +430,4 @@
#endif /* compiler */
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
22 include/stlsoft/internal/cccap/como.h
@@ -4,11 +4,11 @@
* Purpose: Compiler feature discrimination for Comeau C/C++.
*
* Created: 7th February 2003
- * Updated: 11th May 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2003-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2003-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -56,9 +56,9 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_MINOR 15
+# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_MINOR 16
# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_REVISION 1
-# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_EDIT 65
+# define STLSOFT_VER_H_STLSOFT_CCCAP_COMO_EDIT 67
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -331,15 +331,15 @@
* requires that you have defined _STLSOFT_CUSTOM_ASSERT() as a macro
* taking 1 parameter (the condition to assert).
*
- * Suppose you have a function _DisplayAssert(), which has the
+ * Suppose you have a function DisplayAssert_(), which has the
* following signature:
*
- * void _DisplayAssert(char const* file, int line, char const* expression);
+ * void DisplayAssert_(char const* file, int line, char const* expression);
*
* Presumably you would also have your own assert macro, say MY_ASSERT(),
* defined as:
*
- * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(_DisplayAssert(__FILE__, __LINE__, #_x))) : ((void)0)))
+ * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(DisplayAssert_(__FILE__, __LINE__, #_x))) : ((void)0)))
*
* so you would simply need to define _STLSOFT_CUSTOM_ASSERT() in terms of
* MY_ASSERT(), as in:
@@ -381,6 +381,7 @@
# if defined(STLSOFT_CF_COMO_BACKEND_IS_BORLAND)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_FASTCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
@@ -390,6 +391,7 @@
# elif defined(STLSOFT_CF_COMO_BACKEND_IS_DMC)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
# define STLSOFT_CDECL __cdecl
@@ -400,6 +402,7 @@
# if defined(WIN32) || \
defined(WIN64)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_FASTCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
@@ -414,6 +417,7 @@
# if defined(WIN32) || \
defined(WIN64)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_FASTCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
@@ -428,6 +432,7 @@
# if defined(WIN32) || \
defined(WIN64)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_FASTCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
@@ -439,6 +444,7 @@
# elif defined(STLSOFT_CF_COMO_BACKEND_IS_MSVC)
+# define STLSOFT_CF_THISCALL_SUPPORTED
# define STLSOFT_CF_FASTCALL_SUPPORTED
# define STLSOFT_CF_STDCALL_SUPPORTED
@@ -471,4 +477,4 @@
* Compiler warning suppression
*/
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
17 include/stlsoft/internal/cccap/dmc.h
@@ -4,11 +4,11 @@
* Purpose: Compiler feature discrimination for Digital Mars C/C++.
*
* Created: 7th February 2003
- * Updated: 11th May 2008
+ * Updated: 21st July 2009
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2003-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2003-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -56,9 +56,9 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_MINOR 17
+# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_MINOR 18
# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_REVISION 1
-# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_EDIT 88
+# define STLSOFT_VER_H_STLSOFT_CCCAP_DMC_EDIT 90
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -391,15 +391,15 @@
* requires that you have defined _STLSOFT_CUSTOM_ASSERT() as a macro
* taking 1 parameter (the condition to assert).
*
- * Suppose you have a function _DisplayAssert(), which has the
+ * Suppose you have a function DisplayAssert_(), which has the
* following signature:
*
- * void _DisplayAssert(char const* file, int line, char const* expression);
+ * void DisplayAssert_(char const* file, int line, char const* expression);
*
* Presumably you would also have your own assert macro, say MY_ASSERT(),
* defined as:
*
- * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(_DisplayAssert(__FILE__, __LINE__, #_x))) : ((void)0)))
+ * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(DisplayAssert_(__FILE__, __LINE__, #_x))) : ((void)0)))
*
* so you would simply need to define _STLSOFT_CUSTOM_ASSERT() in terms of
* MY_ASSERT(), as in:
@@ -428,6 +428,7 @@
* Calling convention
*/
+#define STLSOFT_CF_THISCALL_SUPPORTED
#define STLSOFT_CF_CDECL_SUPPORTED
#define STLSOFT_CF_STDCALL_SUPPORTED
@@ -455,4 +456,4 @@
* Compiler warning suppression
*/
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
46 include/stlsoft/internal/cccap/gcc.h
@@ -4,7 +4,7 @@
* Purpose: Compiler feature discrimination for GNU C/C++.
*
* Created: 7th February 2003
- * Updated: 17th January 2009
+ * Updated: 21st July 2009
*
* Thanks: To Sergey Nikulov, for PowerPC (BSD) compatibility fixes
*
@@ -58,9 +58,9 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_MINOR 18
-# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_REVISION 5
-# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_EDIT 79
+# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_MINOR 19
+# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_REVISION 1
+# define STLSOFT_VER_H_STLSOFT_CCCAP_GCC_EDIT 82
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -103,29 +103,31 @@
* - variadic macros
*/
-/* #define STLSOFT_PPF_pragma_message_SUPPORT */
+/*
+#define STLSOFT_PPF_pragma_message_SUPPORT
+*/
#if __GNUC__ > 3 || \
( __GNUC__ == 3 && \
__GNUC_MINOR__ >= 4)
# define STLSOFT_PPF_pragma_once_SUPPORT
-#endif /* __GNUC__ */
+#endif /* compiler */
#if __GNUC__ > 4 || \
( __GNUC__ == 4 && \
__GNUC_MINOR__ >= 3)
# define STLSOFT_PPF_COUNTER_SYMBOL_SUPPORT
-#endif /* __GNUC__ */
+#endif /* compiler */
#if __GNUC__ >= 3
# define STLSOFT_PPF_FUNCTION_SYMBOL_SUPPORT
-#endif /* __GNUC__ */
+#endif /* compiler */
#if __GNUC__ > 3 || \
( __GNUC__ == 3 && \
__GNUC_MINOR__ >= 4)
# define STLSOFT_PPF_VARIADIC_MACROS_SUPPORT
-#endif /* __GNUC__ */
+#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
* Support for built-in types
@@ -204,9 +206,9 @@
#if __GNUC__ >= 4
# define STLSOFT_CF_C99_INLINE
-#else /* ? __GNUC__ */
+#else /* ? compiler */
# define STLSOFT_CUSTOM_C_INLINE __inline__
-#endif /* __GNUC__ */
+#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
* Support for C++ language features - 1
@@ -264,7 +266,7 @@
( __GNUC__ == 3 && \
__GNUC_MINOR__ >= 4)
# define STLSOFT_CF_TEMPLATE_QUALIFIER_KEYWORD_SUPPORT
-#endif /* 3.4+ */
+#endif /* compiler */
#define STLSOFT_CF_TYPENAME_PARAM_KEYWORD_SUPPORT
@@ -280,7 +282,7 @@
#if __GNUC__ >= 3
# define STLSOFT_CF_STATIC_ARRAY_SIZE_DETERMINATION_SUPPORT
-#endif /* 2.95+ */
+#endif /* compiler */
/* #define STLSOFT_CF_MOVE_CONSTRUCTOR_SUPPORT */
@@ -330,7 +332,7 @@
#if __GNUC__ >= 3
# define STLSOFT_CF_TEMPLATE_MEMBER_RANGE_FUNCTION_TEMPLATE_SUPPORT
-#endif /* __GNUC__ */
+#endif /* compiler */
#define STLSOFT_CF_TEMPLATE_CTOR_TEMPLATE_SUPPORT
@@ -352,7 +354,7 @@
#if __GNUC__ >= 3
# define STLSOFT_CF_TEMPLATE_CONSTRUCTOR_TEMPLATE_OVERLOAD_DISCRIMINATED_AGAINST_NON_TEMPLATE_CONSTRUCTOR
-#endif /* __GNUC__ */
+#endif /* compiler */
/* #define STLSOFT_CF_TEMPLATE_COPY_CONSTRUCTOR_TEMPLATE_OVERLOAD_DISCRIMINATED_AGAINST_NON_TEMPLATE_COPY_CONSTRUCTOR */
@@ -371,6 +373,8 @@
#if defined(WIN32)
+# define STLSOFT_CF_THISCALL_SUPPORTED
+
# ifdef STLSOFT_CF_CDECL_SUPPORTED
# define STLSOFT_CDECL __cdecl
# endif /* STLSOFT_CF_CDECL_SUPPORTED */
@@ -505,7 +509,7 @@
#if __GNUC__ >= 3
# define STLSOFT_CF_std_char_traits_AVAILABLE
-#endif /* */
+#endif /* compiler */
#define STLSOFT_CF_PARENT_TYPES_CAN_BE_USED_IN_NON_TEMPLATE
@@ -513,7 +517,7 @@
#if __GNUC__ >= 3
# define STLSOFT_CF_VENEER_SUPPORT
-#endif /* */
+#endif /* compiler */
#define STLSOFT_CF_ALLOCATOR_BASE_EXPENSIVE
@@ -533,15 +537,15 @@
* requires that you have defined _STLSOFT_CUSTOM_ASSERT() as a macro
* taking 1 parameter (the condition to assert).
*
- * Suppose you have a function _DisplayAssert(), which has the
+ * Suppose you have a function DisplayAssert_(), which has the
* following signature:
*
- * void _DisplayAssert(char const* file, int line, char const* expression);
+ * void DisplayAssert_(char const* file, int line, char const* expression);
*
* Presumably you would also have your own assert macro, say MY_ASSERT(),
* defined as:
*
- * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(_DisplayAssert(__FILE__, __LINE__, #_x))) : ((void)0)))
+ * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(DisplayAssert_(__FILE__, __LINE__, #_x))) : ((void)0)))
*
* so you would simply need to define _STLSOFT_CUSTOM_ASSERT() in terms of
* MY_ASSERT(), as in:
@@ -576,4 +580,4 @@
#include <stlsoft/internal/cccap/obsolete.h>
-/* ////////////////////////////////////////////////////////////////////// */
+/* ///////////////////////////// end of file //////////////////////////// */
View
659 include/stlsoft/internal/cccap/intel.h
@@ -4,11 +4,14 @@
* Purpose: Compiler feature discrimination for Intel C/C++.
*
* Created: 7th February 2003
- * Updated: 11th May 2008
+ * Updated: 21st July 2009
+ *
+ * Thanks: To Derek Baikie for working on the
+ * Win64-compatibility.
*
* Home: http://stlsoft.org/
*
- * Copyright (c) 2003-2008, Matthew Wilson and Synesis Software
+ * Copyright (c) 2003-2009, Matthew Wilson and Synesis Software
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -52,16 +55,41 @@
# error This file cannot be included more than once in any compilation unit
#endif /* STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL */
+#ifndef STLSOFT_COMPILER_IS_INTEL
+# error This file has been erroneously included for a compiler other than Intel C/C++
+#endif /* compiler */
+
/* ////////////////////////////////////////////////////////////////////// */
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_MINOR 17
+# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_MINOR 18
# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_REVISION 1
-# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_EDIT 75
+# define STLSOFT_VER_H_STLSOFT_CCCAP_INTEL_EDIT 77
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
+ * Structure:
+ *
+ * - auto-generation and compatibility
+ * - preprocessor features
+ * - support for built-in types
+ * - built-in type characteristics
+ * - support for C/C++ language features
+ * - support for C language features
+ * - support for C++ language features - 1
+ * - support for C++ language features - 2
+ * - inline assembler
+ * - calling convention
+ * - integer sizes
+ * - size-specific integer types
+ * - still to-be-determined features
+ * - assertions
+ * - compiler warning suppression
+ * - obsolete features
+ */
+
+/* /////////////////////////////////////////////////////////////////////////
* Auto-generation and compatibility
*/
@@ -71,116 +99,359 @@
*/
/* /////////////////////////////////////////////////////////////////////////
- * Compiler features
+ * Compiler features / compatibility
*/
+#if defined(_MSC_VER) && \
+ _MSC_VER < 1200
+# error STLSoft does not support Intel C/C++ in compatibility mode with versions of Visual C++ less than 6.0
+#endif
+
/* For this to work, -Qvc7.1 must be defined. */
#if __INTEL_COMPILER == 700 && \
_MSC_VER == 1310
# define STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL_7_1
#endif /* __INTEL_COMPILER == 700 && _MSC_VER == 1310 */
-
-/* Messaging
+/* /////////////////////////////////////////////////////////////////////////
+ * Preprocessor features
+ *
+ * - #pragma message
+ * - #pragma once
+ * - __COUNTER__
+ * - __FUNCTION__
+ * - variadic macros
*/
-#define STLSOFT_CF_PRAGMA_MESSAGE_SUPPORT
-
-/* Support for #pragma once
- */
+#define STLSOFT_PPF_pragma_message_SUPPORT
#if __INTEL_COMPILER >= 700
-# define STLSOFT_CF_PRAGMA_ONCE_SUPPORT
-#endif /* __INTEL_COMPILER */
-
-/* Support for __FUNCTION__
- */
+# define STLSOFT_PPF_pragma_once_SUPPORT
+#endif /* compiler */
#if __INTEL_COMPILER >= 700
-# define STLSOFT_CF_FUNCTION_SYMBOL_SUPPORT
-#endif /* __INTEL_COMPILER */
+# define STLSOFT_PPF_COUNTER_SYMBOL_SUPPORT
+#endif /* compiler */
-/* Variadic Macros
- */
+#if __INTEL_COMPILER >= 700
+# define STLSOFT_PPF_FUNCTION_SYMBOL_SUPPORT
+#endif /* compiler */
-/* #define STLSOFT_CF_SUPPORTS_VARIADIC_MACROS */
+/* TODO: check this
+# define STLSOFT_PPF_VARIADIC_MACROS_SUPPORT
+*/
-/* Types:
+/* /////////////////////////////////////////////////////////////////////////
+ * Support for built-in types
+ *
+ * - bool
+ * - wchar_t
+ * - long long
+ * - __int8
+ * - __int16
+ * - __int32
+ * - __int64
+ * - long double
*/
-/* bool */
#if !defined(_MSC_VER) || \
defined(__BOOL_DEFINED)
-# define STLSOFT_CF_NATIVE_BOOL_SUPPORT
-#else
- /* Not defined */
-#endif /* __BOOL_DEFINED */
+# define STLSOFT_CF_BUILTIN_bool_SUPPORT
+#endif /* !_MSC_VER || __BOOL_DEFINED */
+
+#ifdef _NATIVE_WCHAR_T_DEFINED
+# define STLSOFT_CF_BUILTIN_wchar_t_SUPPORT
+#endif /* _NATIVE_WCHAR_T_DEFINED */
+
+/*
+# define STLSOFT_CF_BUILTIN_long_long_SUPPORT
+*/
+
+#define STLSOFT_CF_BUILTIN___int8_SUPPORT
+
+#define STLSOFT_CF_BUILTIN___int16_SUPPORT
+
+#define STLSOFT_CF_BUILTIN___int32_SUPPORT
+
+#if _MSC_VER >= 1020
+# define STLSOFT_CF_BUILTIN___int64_SUPPORT
+#endif /* _MSC_VER >= 1020 */
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Built-in type characteristics
+ *
+ * - char is unsigned
+ * - wchar_t
+ * - synthesised
+ * - available
+ */
-/* char (sign) */
#ifdef _CHAR_UNSIGNED
# define STLSOFT_CF_CHAR_IS_UNSIGNED
#endif /* _CHAR_UNSIGNED */
-/* wchar_t */
-#if defined(_MSC_VER)
-# if _MSC_VER >= 1300
- /* Even though VC 7.0 and 7.1 provide a native wchar_t type, that is __wchar_t,
- * it is not compatible with their libraries (which use the typedef wchar_t),
- * so we cannot use it.
- *
- * wchar_t itself may be used, when _NATIVE_WCHAR_T_DEFINED is defined
- */
-# ifdef _NATIVE_WCHAR_T_DEFINED
-# define STLSOFT_CF_NATIVE_WCHAR_T_SUPPORT
-# elif defined(_WCHAR_T_DEFINED)
-# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
-# else
- /* Not defined */
-# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
-# endif /* _WCHAR_T_DEFINED */
-# else
- /* Previous versions do not have a native type, but do have the typedef wchar_t
- * when _WCHAR_T_DEFINED is defined
- */
-# if defined(_WCHAR_T_DEFINED)
-# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
-# else
- /* Not defined */
-# endif /* _WCHAR_T_DEFINED */
-# endif /* _MSC_VER */
-#endif /* _MSC_VER */
+#if !defined(STLSOFT_CF_BUILTIN_wchar_t_SUPPORT) && \
+ defined(_WCHAR_T_DEFINED)
+# define STLSOFT_CF_wchar_t_IS_SYNTHESISED
+#endif /* !STLSOFT_CF_BUILTIN_wchar_t_SUPPORT && _WCHAR_T_DEFINED */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
-/* ////////////////////////////////////////////////////////////////////// */
+/* /////////////////////////////////////////////////////////////////////////
+ * Support for C/C++ language features
+ *
+ * - return void
+ * - static assertions
+ * - anonymous unions
+ * - -ve % +ve => -ve result
+ */
+
+#if __INTEL_COMPILER >= 700
+# define STLSOFT_CF_return_void_SUPPORT
+#endif /* compiler */
+
+#define STLSOFT_CF_STATIC_ASSERT_SUPPORT
+
+#define STLSOFT_CF_ANONYMOUS_UNION_SUPPORT
+
+#define STLSOFT_CF_NEGATIVE_MODULUS_POSITIVE_GIVES_NEGATIVE_RESULT
/* /////////////////////////////////////////////////////////////////////////
- * Integral types
+ * Support for C language features
*
- * The purpose of this section is to define the following types:
+ * - inline
+ * - C99 inline keyword
+ * - compiler-specific keyword
+ */
+
+/* #define STLSOFT_CF_C99_INLINE_SUPPORT */
+
+#define STLSOFT_CUSTOM_C_INLINE __inline
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Support for C++ language features - 1
*
- * - 8-bit signed and unsigned integers
- * - 16-bit signed and unsigned integers
- * - 32-bit signed and unsigned integers
- * - (optionally) 64-bit signed and unsigned integers
+ * - exceptions
+ * - exception signatures
+ * - exception signatures expense
+ * - operator new throws bad_alloc
+ * - RTTI
+ * - namespaces
+ * - STLSoft namespace(s)?
+ * - member constants
+ * - explicit keyword
+ * - mutable keyword
+ * - template keyword
+ * - typename keyword
+ * - in a template parameter
+ * - type disambiguation inside template bodies
+ * - disambiguation in default template arguments
+ * - type disambiguation inside initialiser lists in class template constructors
+ * - type disambiguation the return types in templates
+ * - argument-dependent lookup
+ * - static array-size determination
+ * - empty-derived optimisation
+ * -
+ * - empty-base optimisation
+ * -
+ * - move constructor support
+ * - operators
+ * - operator bool implemented as pointer-to-member
+ * - operator ! implemented as pointer-to-member
+ */
+
+#ifdef _CPPUNWIND
+# define STLSOFT_CF_EXCEPTION_SUPPORT
+# if defined(_MSC_VER) && \
+ _MSC_VER >= 1100
+# define STLSOFT_CF_EXCEPTION_SIGNATURE_SUPPORT
+# endif /* _MSC_VER */
+/* TODO: check this
+# define STLSOFT_CF_EXCEPTION_SPEC_EXPENSIVE
+*/
+# if ( defined(_MSC_VER) && \
+ _MSC_VER >= 1300) || \
+ ( !defined(_MSC_VER) && \
+ __INTEL_COMPILER >= 900)
+# define STLSOFT_CF_EXCEPTION_OPERATOR_NEW_THROWS_BAD_ALLOC
+# endif /* VC++ 13+ / Intel C/C++ 9+ */
+#endif /* _CPPUNWIND */
+
+#ifdef _CPPRTTI
+# define STLSOFT_CF_RTTI_SUPPORT
+#endif /* _CPPRTTI */
+
+#define STLSOFT_CF_NAMESPACE_SUPPORT
+
+/*
+# define _STLSOFT_NO_NAMESPACES
+*/
+
+#define STLSOFT_CF_MEMBER_CONSTANT_SUPPORT
+
+#define STLSOFT_CF_EXPLICIT_KEYWORD_SUPPORT
+
+#define STLSOFT_CF_MUTABLE_KEYWORD_SUPPORT
+
+/*
+# define STLSOFT_CF_TEMPLATE_QUALIFIER_KEYWORD_SUPPORT
+*/
+
+#define STLSOFT_CF_TYPENAME_PARAM_KEYWORD_SUPPORT
+
+#define STLSOFT_CF_TYPENAME_TYPE_KEYWORD_SUPPORT
+
+#define STLSOFT_CF_TYPENAME_TYPE_DEF_KEYWORD_SUPPORT
+
+#define STLSOFT_CF_TYPENAME_TYPE_MIL_KEYWORD_SUPPORT
+
+#define STLSOFT_CF_TYPENAME_TYPE_RET_KEYWORD_SUPPORT
+
+#if defined(STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL_7_1) || \
+ __INTEL_COMPILER >= 800
+# define STLSOFT_CF_ADL_SUPPORT
+#endif /* STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL_7_1 || __INTEL_COMPILER >= 800 */
+
+#define STLSOFT_CF_STATIC_ARRAY_SIZE_DETERMINATION_SUPPORT
+
+#ifdef _MSC_EXTENSIONS
+# define STLSOFT_CF_MOVE_CONSTRUCTOR_SUPPORT
+#endif /* _MSC_EXTENSIONS */
+
+#if !defined(_MSC_VER) || \
+ _MSC_VER >= 1300
+# define STLSOFT_CF_OPERATOR_BOOL_AS_OPERATOR_POINTER_TO_MEMBER_SUPPORT
+# define STLSOFT_CF_OPERATOR_NOT_VIA_OPERATOR_POINTER_TO_MEMBER_SUPPORT
+#endif /* !_MSC_VER || _MSC_VER >= 1300 */
+
+/*
+# define STLSOFT_CF_REQUIRE_RETURN_ALWAYS
+*/
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Support for C++ language features - 2
*
- * and to define, where appropriate the following symbols (used for
- * overloading):
+ * - templates
+ * - specialisation syntax (template <>)
+ * - partial specialisation
+ * - function template
+ * - class template
+ * - member class template
+ * - member function template
+ * - member range function template
+ * - constructor template
+ * - template template
+ * - class template fundamental argument
+ * - class template type argument
+ * - class template member function argument
+ * - class template default fundamental argument
+ * - class template default type argument
+ * - function template parameter list requires template parameter
+ * - member function template overload is properly discriminated against
+ * other non-template member function
+ * - constructor template overload is properly discriminated against
+ * other non-template constructor
+ * - copy-constructor template overload is properly discriminated against
+ * other non-template copy-constructor
+ */
+
+#define STLSOFT_CF_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_SPECIALISATION_SYNTAX_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_PARTIAL_SPECIALISATION_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_FUNCTION_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_CLASS_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_MEMBER_CLASS_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_MEMBER_FUNCTION_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_MEMBER_RANGE_FUNCTION_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_CTOR_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_TEMPLATE_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_FUNDAMENTAL_PARAMETER_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_TYPE_PARAMETER_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_MEMBER_FUNCTION_PARAMETER_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_DEFAULT_FUNDAMENTAL_PARAMETER_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_DEFAULT_TYPE_PARAMETER_SUPPORT
+
+#define STLSOFT_CF_TEMPLATE_FUNCTION_TEMPLATE_REQUIRES_TEMPLATE_PARAMETERS_IN_FUNCTION_PARAMETER_LIST
+
+#define STLSOFT_CF_TEMPLATE_MEMBER_FUNCTION_TEMPLATE_OVERLOAD_DISCRIMINATED_AGAINST_NON_TEMPLATE_MEMBER_FUNCTION
+
+#define STLSOFT_CF_TEMPLATE_CONSTRUCTOR_TEMPLATE_OVERLOAD_DISCRIMINATED_AGAINST_NON_TEMPLATE_CONSTRUCTOR
+
+/* TODO: check this
+# define STLSOFT_CF_TEMPLATE_COPY_CONSTRUCTOR_TEMPLATE_OVERLOAD_DISCRIMINATED_AGAINST_NON_TEMPLATE_COPY_CONSTRUCTOR
+*/
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Inline assembler
+ */
+
+#if defined(_M_IX86)
+# define STSLSOFT_INLINE_ASM_SUPPORTED
+# define STSLSOFT_ASM_IN_INLINE_SUPPORTED
+#elif defined(_M_IA64) || \
+ defined(_M_X64)
+ /* Inline assembler not supported for Intel C/C++ 64-bit compilers */
+#endif /* arch */
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Calling convention
*
- * - STLSOFT_CF_CHAR_DISTINCT_INT_TYPE
- * - STLSOFT_CF_SHORT_DISTINCT_INT_TYPE
- * - STLSOFT_CF_INT_DISTINCT_INT_TYPE
- * - STLSOFT_CF_LONG_DISTINCT_INT_TYPE
- * - STLSOFT_CF_LONG_LONG_DISTINCT_INT_TYPE
+ * On x86 (Windows), the following are supported:
+ * - cdecl
+ * - fastcall
+ * - stdcall
*
- * which indicate that a given type is not used in the size-specific types.
+ * On IA64/x64 there is only a single calling convention. Calling convention
+ * keywords are ignored.
+ */
+
+#if defined(_M_IX86)
+
+# define STLSOFT_CF_THISCALL_SUPPORTED
+# define STLSOFT_CF_CDECL_SUPPORTED
+# ifndef _MANAGED
+# define STLSOFT_CF_FASTCALL_SUPPORTED
+# endif /* !_MANAGED */
+# define STLSOFT_CF_STDCALL_SUPPORTED
+
+# define STLSOFT_CDECL __cdecl
+# ifndef _MANAGED
+# define STLSOFT_FASTCALL __fastcall
+# endif /* !_MANAGED */
+# define STLSOFT_STDCALL __stdcall
+
+#elif defined(_M_IA64) || \
+ defined(_M_X64)
+
+# define STLSOFT_CF_CDECL_SUPPORTED
+
+# define STLSOFT_CDECL
+
+#elif defined(unix) || \
+ defined(__unix__)
+
+# define STLSOFT_CF_CDECL_SUPPORTED
+
+# define STLSOFT_CDECL
+
+#else /* ? arch */
+# error Only defined for the Intel x86, IA64 and x64 architectures
+#endif /* arch */
+
+/* /////////////////////////////////////////////////////////////////////////
+ * Integer sizes
*/
#if defined(__LP64__)
@@ -200,6 +471,28 @@
# error Use of Intel C/C++ has not been verified on any operation system other than Win32. Please contact Synesis Software
#endif /* data model */
+/* /////////////////////////////////////////////////////////////////////////
+ * Size-specific integer types
+ *
+ * The purpose of this section is to define the following types:
+ *
+ * - 8-bit signed and unsigned integers
+ * - 16-bit signed and unsigned integers
+ * - 32-bit signed and unsigned integers
+ * - (optionally) 64-bit signed and unsigned integers
+ *
+ * and to define, where appropriate the following symbols (used for
+ * overloading):
+ *
+ * - STLSOFT_CF_CHAR_DISTINCT_INT_TYPE
+ * - STLSOFT_CF_SHORT_DISTINCT_INT_TYPE
+ * - STLSOFT_CF_INT_DISTINCT_INT_TYPE
+ * - STLSOFT_CF_LONG_DISTINCT_INT_TYPE
+ * - STLSOFT_CF_LONG_LONG_DISTINCT_INT_TYPE
+ *
+ * which indicate that a given type is not used in the size-specific types.
+ */
+
/* 8-bit integer */
#define STLSOFT_CF_8BIT_INT_SUPPORT
#define STLSOFT_SI08_T_BASE_TYPE signed __int8
@@ -231,78 +524,39 @@
#define STLSOFT_SI64_T_BASE_TYPE signed __int64
#define STLSOFT_UI64_T_BASE_TYPE unsigned __int64
+/* /////////////////////////////////////////////////////////////////////////
+ * Still to-be-determined features
+ */
-
-/* Member constants */
-#define STLSOFT_CF_MEMBER_CONSTANT_SUPPORT
-
-/* Static assertions */
-#define STLSOFT_CF_STATIC_ASSERT_SUPPORT
-
-/* RTTI support */
-#ifdef _CPPRTTI
-# define STLSOFT_CF_RTTI_SUPPORT
-#else /* ? _CPPRTTI */
- /* Not defined */
-#endif /* _CPPRTTI */
-
-/* Exception support */
-#ifdef _CPPUNWIND
-# define STLSOFT_CF_EXCEPTION_SUPPORT
-#else
- /* Not defined */
-#endif /* _CPPUNWIND */
-
-/* */
-#define STLSOFT_CF_FUNCTION_SIGNATURE_FULL_ARG_QUALIFICATION_REQUIRED
-
-/* Namespace support */
-/* #define _STLSOFT_NO_NAMESPACES */
-
-#define STLSOFT_CF_NAMESPACE_SUPPORT
-
-#define STLSOFT_CF_ANONYMOUS_UNION_SUPPORT
-
-#define STLSOFT_CF_COMPILER_SUPPORTS_RETURN_VOID
-
-/* Template support */
-#define STLSOFT_CF_TEMPLATE_SUPPORT
-
-/* #define STLSOFT_CF_TEMPLATE_TYPE_REQUIRED_IN_ARGS */
-
-#if defined(_MSC_VER) && \
- _MSC_VER >= 1100
-# ifdef _CPPUNWIND
-# define STLSOFT_CF_EXCEPTION_SIGNATURE_SUPPORT
-# endif /* _CPPUNWIND */
+#if defined(_MSC_VER)
+# if _MSC_VER >= 1300
+ /* Even though VC 7.0 and 7.1 provide a native wchar_t type, that is __wchar_t,
+ * it is not compatible with their libraries (which use the typedef wchar_t),
+ * so we cannot use it.
+ *
+ * wchar_t itself may be used, when _NATIVE_WCHAR_T_DEFINED is defined
+ */
+# ifdef _NATIVE_WCHAR_T_DEFINED
+# define STLSOFT_CF_NATIVE_WCHAR_T_SUPPORT
+# elif defined(_WCHAR_T_DEFINED)
+# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
+# else
+ /* Not defined */
+# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
+# endif /* _WCHAR_T_DEFINED */
+# else
+ /* Previous versions do not have a native type, but do have the typedef wchar_t
+ * when _WCHAR_T_DEFINED is defined
+ */
+# if defined(_WCHAR_T_DEFINED)
+# define STLSOFT_CF_TYPEDEF_WCHAR_T_SUPPORT
+# else
+ /* Not defined */
+# endif /* _WCHAR_T_DEFINED */
+# endif /* _MSC_VER */
#endif /* _MSC_VER */
-/* #define STLSOFT_CF_EXCEPTION_SPEC_EXPENSIVE */
-
-
-/* # define STLSOFT_CF_THROW_BAD_ALLOC */
-
-#define STLSOFT_CF_TEMPLATE_CLASS_DEFAULT_FUNDAMENTAL_ARGUMENT_SUPPORT
-
-#define STLSOFT_CF_TEMPLATE_CLASS_DEFAULT_CLASS_ARGUMENT_SUPPORT
-
-#define STLSOFT_CF_MEM_FUNC_AS_TEMPLATE_PARAM_SUPPORT
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_FUNCTION_SUPPORT
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_OVERLOAD_DISCRIMINATED
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_CTOR_SUPPORT
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_CTOR_OVERLOAD_DISCRIMINATED
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_RANGE_METHOD_SUPPORT
-
-#define STLSOFT_CF_MEMBER_TEMPLATE_CLASS_SUPPORT
-
-#define STLSOFT_CF_TEMPLATE_SPECIALISATION_SYNTAX
-
-#define STLSOFT_CF_TEMPLATE_PARTIAL_SPECIALISATION_SUPPORT
+#define STLSOFT_CF_FUNCTION_SIGNATURE_FULL_ARG_QUALIFICATION_REQUIRED
#define STLSOFT_CF_TEMPLATE_OUTOFCLASSFN_QUALIFIED_TYPE_SUPPORT
@@ -311,56 +565,20 @@
#define STLSOFT_CF_std_char_traits_AVAILABLE
#define STLSOFT_CF_PARENT_TYPES_CAN_BE_USED_IN_NON_TEMPLATE
-
#define STLSOFT_CF_PARENT_TYPES_CAN_BE_USED_IN_TEMPLATE
-#define STLSOFT_CF_EXPLICIT_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_MUTABLE_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_TYPENAME_PARAM_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_TYPENAME_TYPE_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_TYPENAME_TYPE_DEF_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_TYPENAME_TYPE_MIL_KEYWORD_SUPPORT
-
-#define STLSOFT_CF_TYPENAME_TYPE_RET_KEYWORD_SUPPORT
-
-/* #define STLSOFT_CF_TEMPLATE_QUALIFIER_KEYWORD_SUPPORT */
-
-#ifdef _MSC_EXTENSIONS
-# define STLSOFT_CF_MOVE_CONSTRUCTOR_SUPPORT
-#endif /* _MSC_EXTENSIONS */
-
-#if defined(STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL_7_1) || \
- __INTEL_COMPILER >= 800
-# define STLSOFT_CF_ADL_LOOKUP_SUPPORT
-#endif /* STLSOFT_INCL_H_STLSOFT_CCCAP_INTEL_7_1 || __INTEL_COMPILER >= 800 */
-
-#define STLSOFT_CF_TEMPLATE_TEMPLATE_SUPPORT
-
-#define STLSOFT_CF_STATIC_ARRAY_SIZE_DETERMINATION_SUPPORT
-
#define STLSOFT_CF_VENEER_SUPPORT
#if !defined(_ATL_MIN_CRT)
# define STLSOFT_CF_ALLOCATOR_BASE_EXPENSIVE
#endif /* !_ATL_MIN_CRT */
-/* #define STLSOFT_CF_COMPILER_WARNS_NO_PUBLIC_DTOR */
-
-/* Shims are supported. */
-/* #define STLSOFT_CF_TEMPLATE_SHIMS_NOT_SUPPORTED */
-
-#define STLSOFT_CF_NEGATIVE_MODULUS_POSITIVE_GIVES_NEGATIVE_RESULT
-
-#if !defined(_MSC_VER) || \
- _MSC_VER >= 1300
-# define STLSOFT_CF_OPERATOR_BOOL_AS_OPERATOR_POINTER_TO_MEMBER_SUPPORT
-# define STLSOFT_CF_OPERATOR_NOT_VIA_OPERATOR_POINTER_TO_MEMBER_SUPPORT
-#endif /* !_MSC_VER || _MSC_VER >= 1300 */
+/*
+# define STLSOFT_CF_COMPILER_WARNS_NO_PUBLIC_DTOR
+*/
+/*
+# define STLSOFT_CF_TEMPLATE_SHIMS_NOT_SUPPORTED
+*/
/* /////////////////////////////////////////////////////////////////////////
* Quality assurance features
@@ -372,15 +590,15 @@
* requires that you have defined _STLSOFT_CUSTOM_ASSERT() as a macro
* taking 1 parameter (the condition to assert).
*
- * Suppose you have a function _DisplayAssert(), which has the
+ * Suppose you have a function DisplayAssert_(), which has the
* following signature:
*
- * void _DisplayAssert(char const* file, int line, char const* expression);
+ * void DisplayAssert_(char const* file, int line, char const* expression);
*
* Presumably you would also have your own assert macro, say MY_ASSERT(),
* defined as:
*
- * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(_DisplayAssert(__FILE__, __LINE__, #_x))) : ((void)0)))
+ * #define MY_ASSERT(_x) ((void)((!(_x)) ? ((void)(DisplayAssert_(__FILE__, __LINE__, #_x))) : ((void)0)))
*
* so you would simply need to define _STLSOFT_CUSTOM_ASSERT() in terms of
* MY_ASSERT(), as in:
@@ -394,7 +612,7 @@
# define STLSOFT_ASSERT(_x) _STLSOFT_CUSTOM_ASSERT(_x)
# if defined(_STLSOFT_CUSTOM_ASSERT_INCLUDE)
# define __STLSOFT_CF_ASSERT_INCLUDE_NAME _STLSOFT_CUSTOM_ASSERT_INCLUDE
-# else
+# else /* ? _STLSOFT_CUSTOM_ASSERT_INCLUDE */
# error You must define _STLSOFT_CUSTOM_ASSERT_INCLUDE along with _STLSOFT_CUSTOM_ASSERT()
# endif /* !_STLSOFT_CUSTOM_ASSERT_INCLUDE */
#else /* ? _STLSOFT_CUSTOM_ASSERT */
@@ -417,49 +635,6 @@
#endif /* _STLSOFT_CUSTOM_ASSERT */
/* /////////////////////////////////////////////////////////////////////////
- * Calling convention
- */
-
-#define STLSOFT_CF_CDECL_SUPPORTED
-
-#if !defined(unix) && \
- !defined(__unix__)
-
-# define STLSOFT_CF_FASTCALL_SUPPORTED
-# define STLSOFT_CF_STDCALL_SUPPORTED
-
-# ifdef STLSOFT_CF_CDECL_SUPPORTED
-# define STLSOFT_CDECL __cdecl
-# endif /* STLSOFT_CF_CDECL_SUPPORTED */
-# ifdef STLSOFT_CF_FASTCALL_SUPPORTED
-# define STLSOFT_FASTCALL __fastcall
-# endif /* STLSOFT_CF_FASTCALL_SUPPORTED */
-# ifdef STLSOFT_CF_STDCALL_SUPPORTED
-# define STLSOFT_STDCALL __stdcall
-# endif /* STLSOFT_CF_STDCALL_SUPPORTED */
-
-#else /* ? UNIX */
-
-# ifdef STLSOFT_CF_CDECL_SUPPORTED
-# define STLSOFT_CDECL
-# endif /* STLSOFT_CF_CDECL_SUPPORTED */
-
-#endif /* !unix && !__unix__ */
-
-/* /////////////////////////////////////////////////////////////////////////
- * Inline assembler
- */
-
-#define STSLSOFT_INLINE_ASM_SUPPORTED
-#define STSLSOFT_ASM_IN_INLINE_SUPPORTED
-
-/* /////////////////////////////////////////////////////////////////////////
- * inline support
- */
-
-#define STLSOFT_CUSTOM_C_INLINE __inline
-
-/* /////////////////////////////////////////////////////////////////////////
* Compiler warning suppression
*/
@@ -479,4 +654,10 @@
/* Suppresses: "operands are evaluated in unspecified order" */
#pragma warning(disable : 981)
-/* ////////////////////////////////////////////////////////////////////// */
+/* /////////////////////////////////////////////////////////////////////////
+ * Obsolete features
+ */
+
+#include <stlsoft/internal/cccap/obsolete.h>
+
+/* ///////////////////////////// end of file //////////////////////////// */
View
176 include/stlsoft/internal/cccap/msvc.h
@@ -4,7 +4,7 @@
* Purpose: Compiler feature discrimination for Visual C++.
*
* Created: 7th February 2003
- * Updated: 4th March 2009
+ * Updated: 21st July 2009
*
* Thanks: To Cláudio Albuquerque for working on the
* Win64-compatibility.
@@ -63,9 +63,9 @@
#ifndef STLSOFT_DOCUMENTATION_SKIP_SECTION
# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_MAJOR 3
-# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_MINOR 19
-# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_REVISION 5
-# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_EDIT 107
+# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_MINOR 20
+# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_REVISION 1
+# define STLSOFT_VER_H_STLSOFT_CCCAP_MSVC_EDIT 111
#endif /* !STLSOFT_DOCUMENTATION_SKIP_SECTION */
/* /////////////////////////////////////////////////////////////////////////
@@ -112,19 +112,19 @@
#if _MSC_VER >= 900
# define STLSOFT_PPF_pragma_once_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_PPF_COUNTER_SYMBOL_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_PPF_FUNCTION_SYMBOL_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1400
# define STLSOFT_PPF_VARIADIC_MACROS_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
* Support for built-in types
@@ -147,7 +147,9 @@
# define STLSOFT_CF_BUILTIN_wchar_t_SUPPORT
#endif /* _NATIVE_WCHAR_T_DEFINED */
-/* # define STLSOFT_CF_BUILTIN_long_long_SUPPORT */
+/*
+# define STLSOFT_CF_BUILTIN_long_long_SUPPORT
+*/
#define STLSOFT_CF_BUILTIN___int8_SUPPORT
@@ -157,7 +159,7 @@
#if _MSC_VER >= 1020
# define STLSOFT_CF_BUILTIN___int64_SUPPORT
-#endif /* _MSC_VER >= 1020 */
+#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
* Built-in type characteristics
@@ -188,7 +190,7 @@
#if _MSC_VER >= 1300
# define STLSOFT_CF_return_void_SUPPORT
-#endif /* _MSC_VER >= 1300 */
+#endif /* compiler */
#define STLSOFT_CF_STATIC_ASSERT_SUPPORT
@@ -244,11 +246,13 @@
# define STLSOFT_CF_EXCEPTION_SUPPORT
# if _MSC_VER >= 1100
# define STLSOFT_CF_EXCEPTION_SIGNATURE_SUPPORT
-# endif /* _MSC_VER */
-/* # define STLSOFT_CF_EXCEPTION_SPEC_EXPENSIVE */
+# endif /* compiler */
+/*
+# define STLSOFT_CF_EXCEPTION_SPEC_EXPENSIVE
+*/
# if _MSC_VER >= 1300
# define STLSOFT_CF_EXCEPTION_OPERATOR_NEW_THROWS_BAD_ALLOC
-# endif /* _MSC_VER */
+# endif /* compiler */
#endif /* _CPPUNWIND */
#ifdef _CPPRTTI
@@ -257,7 +261,7 @@
#if _MSC_VER >= 1020
# define STLSOFT_CF_NAMESPACE_SUPPORT
-#endif /* _MSC_VER >= 1020 */
+#endif /* compiler */
#if _MSC_VER < 1100
/* Since Visual C++ 4.2 and earlier do not correctly support using declarations
@@ -265,49 +269,51 @@
* too painful to use, so namespaces are suppressed.
*/
# define _STLSOFT_NO_NAMESPACES
-#endif /* _MSC_VER < 1100 */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_CF_MEMBER_CONSTANT_SUPPORT
-#endif /* _MSC_VER > 1300 */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_EXPLICIT_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_MUTABLE_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_CF_TEMPLATE_QUALIFIER_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TYPENAME_PARAM_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1200
# define STLSOFT_CF_TYPENAME_TYPE_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_CF_TYPENAME_TYPE_DEF_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
-/* # define STLSOFT_CF_TYPENAME_TYPE_MIL_KEYWORD_SUPPORT */
+/*
+# define STLSOFT_CF_TYPENAME_TYPE_MIL_KEYWORD_SUPPORT
+*/
#if _MSC_VER >= 1300
# define STLSOFT_CF_TYPENAME_TYPE_RET_KEYWORD_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1310
# define STLSOFT_CF_ADL_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1300
# define STLSOFT_CF_STATIC_ARRAY_SIZE_DETERMINATION_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if defined(_MSC_EXTENSIONS) && \
_MSC_VER < 1310
@@ -317,11 +323,11 @@
#if _MSC_VER >= 1300
# define STLSOFT_CF_OPERATOR_BOOL_AS_OPERATOR_POINTER_TO_MEMBER_SUPPORT
# define STLSOFT_CF_OPERATOR_NOT_VIA_OPERATOR_POINTER_TO_MEMBER_SUPPORT
-#endif /* _MSC_VER >= 1300 */
+#endif /* compiler */
#if _MSC_VER <= 1200
# define STLSOFT_CF_REQUIRE_RETURN_ALWAYS
-#endif /* _MSC_VER <= 1200 */
+#endif /* compiler */
/* /////////////////////////////////////////////////////////////////////////
* Support for C++ language features - 2
@@ -352,89 +358,88 @@
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_SPECIALISATION_SYNTAX_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1310
# define STLSOFT_CF_TEMPLATE_PARTIAL_SPECIALISATION_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_FUNCTION_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_CLASS_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_MEMBER_CLASS_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1100
# define STLSOFT_CF_TEMPLATE_MEMBER_FUNCTION_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
#if _MSC_VER >= 1200
# define STLSOFT_CF_TEMPLATE_MEMBER_RANGE_FUNCTION_TEMPLATE_SUPPORT
-#endif /* _MSC_VER */
+#endif /* compiler */
/* Although VC++ 5.0 does work with this in isolated cases, in practice it experiences
* too many internal compiler errors, or compiler lock-ups, to make it tolerable