[pygccxml-commit] SF.net SVN: pygccxml:[1484] gccxml_bin/v09/win32
Brought to you by:
mbaas,
roman_yakovenko
|
From: <rom...@us...> - 2008-12-22 22:59:21
|
Revision: 1484
http://pygccxml.svn.sourceforge.net/pygccxml/?rev=1484&view=rev
Author: roman_yakovenko
Date: 2008-12-22 22:11:51 +0000 (Mon, 22 Dec 2008)
Log Message:
-----------
update gccxml
Modified Paths:
--------------
gccxml_bin/v09/win32/bin/gccxml.exe
gccxml_bin/v09/win32/bin/gccxml_cc1plus.exe
gccxml_bin/v09/win32/bin/gccxml_vcconfig.exe
gccxml_bin/v09/win32/share/gccxml-0.9/Intel/find_flags
gccxml_bin/v09/win32/share/gccxml-0.9/MIPSpro/find_flags
gccxml_bin/v09/win32/share/gccxml-0.9/gccxml_config
gccxml_bin/v09/win32/share/man/man1/gccxml.1
Added Paths:
-----------
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/CodeAnalysis/
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/CodeAnalysis/sourceannotations.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/algorithm
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/crtdbg.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/crtdefs.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/crtdefs.h.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/deque
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/eh.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/iosfwd
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/iterator
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/limits
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/list
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/locale
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/memory
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/sal.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/setjmp.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/typeinfo
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/vector
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/vector.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xhash
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xhash.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xlocale
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xlocmes
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xlocmon
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xlocnum
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xlocnum.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xloctime
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xstddef
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xutility
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/xutility.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/yvals.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/yvals.h.orig
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/OAIdl.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/ObjBase.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/PropIdl.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/WinNT.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/ktmtypes.h
gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/PlatformSDK/specstrings_strict.h
Removed Paths:
-------------
gccxml_bin/v09/win32/share/gccxml-0.9/GCC/find_flags
gccxml_bin/v09/win32/share/gccxml-0.9/gccxml_find_flags
Modified: gccxml_bin/v09/win32/bin/gccxml.exe
===================================================================
(Binary files differ)
Modified: gccxml_bin/v09/win32/bin/gccxml_cc1plus.exe
===================================================================
(Binary files differ)
Modified: gccxml_bin/v09/win32/bin/gccxml_vcconfig.exe
===================================================================
(Binary files differ)
Deleted: gccxml_bin/v09/win32/share/gccxml-0.9/GCC/find_flags
===================================================================
--- gccxml_bin/v09/win32/share/gccxml-0.9/GCC/find_flags 2008-12-21 22:28:17 UTC (rev 1483)
+++ gccxml_bin/v09/win32/share/gccxml-0.9/GCC/find_flags 2008-12-22 22:11:51 UTC (rev 1484)
@@ -1,112 +0,0 @@
-#!/bin/sh
-#=============================================================================
-#
-# Program: GCC-XML
-# Module: $RCSfile: find_flags,v $
-# Language: C++
-# Date: $Date: 2008-08-07 15:36:08 $
-# Version: $Revision: 1.23 $
-#
-# Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
-# See Copyright.txt for details.
-#
-# This software is distributed WITHOUT ANY WARRANTY; without even
-# the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
-# PURPOSE. See the above copyright notices for more information.
-#
-#=============================================================================
-
-# Find the GCC executable name.
-if test "x$1" = "x" ; then
- if test "x${CXX}" = "x" ; then
- CXX=gcc
- fi
-else
- CXX="$1"
- shift
- CXXFLAGS="$@"
-fi
-
-# Find the macro definition options.
-MACROS=`echo "" | ${CXX} -x c++ -E -dM ${CXXFLAGS} - 2>/dev/null |
- sed -n '
-/^#define / {s/#define \([A-Za-z_][A-Za-z0-9_()]*\) \(.*\)/-D\1='\''\2'\''/;p;}
-' |
- awk '
-BEGIN { first=1 }
-/./ { if(first) { printf("%s", $0); first=0 } else { printf(" %s", $0) } }
-'`
-
-# Find the include path options.
-INCLUDES=`
- echo "" | ${CXX} -v -x c++ -E ${CXXFLAGS} - 2>&1 |
- awk '/^[^ \/].*$/ { if (f) { printf("\n"); exit } }
- /^[ ]*(\/[^ ]*)( \(.*\))?$/ {
- if (f) {
- if (match($1,"/Frameworks")) {
- printf("-F%s ",$1)
- } else {
- printf("-isystem%s ",$1)
- }
- }
- }
- /\#include <\.\.\..*$/ {f=1} ' -
-`
-
-# The support headers are located where this script is.
-SELFPATH=`echo $0 | sed -n '/\//{s/\/find_flags//;p;}'`
-if test "x$SELFPATH" = "x" ; then SELFPATH="." ; fi
-SELFPATH=`cd "$SELFPATH" ; pwd`
-
-# Determine the major version number.
-MAJOR_VERSION=`
-echo "__GNUC__" | ${CXX} -v -x c++ -E ${CXXFLAGS} - 2>/dev/null |
- sed -n '/^[0-9]/{s/[^0-9]//g;p;}'`
-
-MINOR_VERSION=`
-echo "__GNUC_MINOR__" | ${CXX} -v -x c++ -E ${CXXFLAGS} - 2>/dev/null |
- sed -n '/^[0-9]/{s/[^0-9]//g;p;}'`
-
-# hack to handle bad gcc 4.0 on RedHat
-if [ "$MAJOR_VERSION" = 4 ]; then
- if echo "$INCLUDES" | grep "c++/3\.4" > /dev/null 2>&1; then
- MAJOR_VERSION=3
- MINOR_VERSION=4
- fi
-fi
-
-# For GCC versions before 3, some special options are needed.
-if [ "$MAJOR_VERSION" -lt 3 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/2.95\" $INCLUDES"
- if [ "$MINOR_VERSION" = 96 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/2.96\" $INCLUDES"
- fi
-elif [ "$MAJOR_VERSION" = 4 -a "$MINOR_VERSION" -ge 3 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/4.3\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 4 -a "$MINOR_VERSION" -ge 2 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/4.2\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 4 -a "$MINOR_VERSION" -ge 1 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/4.1\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 4 -a "$MINOR_VERSION" -ge 0 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/4.0\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 3 -a "$MINOR_VERSION" -ge 4 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/3.4\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 3 -a "$MINOR_VERSION" = 3 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/3.3\" $INCLUDES"
- SPECIAL="-include \"gccxml_builtins.h\""
-elif [ "$MAJOR_VERSION" = 3 -a "$MINOR_VERSION" = 2 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/3.2\" $INCLUDES"
-elif [ "$MAJOR_VERSION" = 3 -a "$MINOR_VERSION" = 1 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/3.1\" $INCLUDES"
-elif [ "$MAJOR_VERSION" = 3 -a "$MINOR_VERSION" = 0 ]; then
- INCLUDES="-iwrapper\"$SELFPATH/3.0\" $INCLUDES"
-fi
-
-# Format and print out the options.
-OPTIONS="$MACROS $INCLUDES $SPECIAL"
-echo $OPTIONS
Modified: gccxml_bin/v09/win32/share/gccxml-0.9/Intel/find_flags
===================================================================
--- gccxml_bin/v09/win32/share/gccxml-0.9/Intel/find_flags 2008-12-21 22:28:17 UTC (rev 1483)
+++ gccxml_bin/v09/win32/share/gccxml-0.9/Intel/find_flags 2008-12-22 22:11:51 UTC (rev 1484)
@@ -1,56 +1,56 @@
-#!/bin/sh
-#=============================================================================
-#
-# Program: GCC-XML
-# Module: $RCSfile: find_flags,v $
-# Language: C++
-# Date: $Date: 2005/04/07 12:51:07 $
-# Version: $Revision: 1.5 $
-#
-# Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
-# See Copyright.txt for details.
-#
-# This software is distributed WITHOUT ANY WARRANTY; without even
-# the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
-# PURPOSE. See the above copyright notices for more information.
-#
-#=============================================================================
-
-# Find the GCC executable name.
-if test "x$1" = "x" ; then
- if test "x${CXX}" = "x" ; then
- CXX=gcc
- fi
-else
- CXX="$1"
- shift
- CXXFLAGS="$@"
-fi
-
-# Find the macro definition options.
-MACROS=`echo "" | ${CXX} -x c++ -E -dM ${CXXFLAGS} - 2>/dev/null |
- sed -n '
-/^#define / {s/#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)/-D\1='\''\2'\''/;p;}
-' |
- awk '
-BEGIN { first=1 }
-/./ { if(first) { printf("%s", $0); first=0 } else { printf(" %s", $0) } }
-'`
-
-# Find the include path options.
-INCLUDES=`
- echo "" | ${CXX} -v -x c++ -E ${CXXFLAGS} - 2>&1 |
- awk '/^[ \t]*-I\/.* \\\\$/ { printf("%s ",$1) }
- END {printf("\n")}' -
-`
-
-# The support headers are located where this script is.
-SELFPATH=`echo $0 | sed -n '/\//{s/\/find_flags//;p;}'`
-if test "x$SELFPATH" = "x" ; then SELFPATH="." ; fi
-SELFPATH=`cd "$SELFPATH" ; pwd`
-
-INCLUDES="-iwrapper\"$SELFPATH\" $INCLUDES"
-
-# Format and print out the options.
-OPTIONS="$MACROS -D_WCHAR_T $INCLUDES"
-echo $OPTIONS
+#!/bin/sh
+#=============================================================================
+#
+# Program: GCC-XML
+# Module: $RCSfile: find_flags,v $
+# Language: C++
+# Date: $Date: 2005-04-07 12:51:07 $
+# Version: $Revision: 1.5 $
+#
+# Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
+# See Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even
+# the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+# PURPOSE. See the above copyright notices for more information.
+#
+#=============================================================================
+
+# Find the GCC executable name.
+if test "x$1" = "x" ; then
+ if test "x${CXX}" = "x" ; then
+ CXX=gcc
+ fi
+else
+ CXX="$1"
+ shift
+ CXXFLAGS="$@"
+fi
+
+# Find the macro definition options.
+MACROS=`echo "" | ${CXX} -x c++ -E -dM ${CXXFLAGS} - 2>/dev/null |
+ sed -n '
+/^#define / {s/#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)/-D\1='\''\2'\''/;p;}
+' |
+ awk '
+BEGIN { first=1 }
+/./ { if(first) { printf("%s", $0); first=0 } else { printf(" %s", $0) } }
+'`
+
+# Find the include path options.
+INCLUDES=`
+ echo "" | ${CXX} -v -x c++ -E ${CXXFLAGS} - 2>&1 |
+ awk '/^[ \t]*-I\/.* \\\\$/ { printf("%s ",$1) }
+ END {printf("\n")}' -
+`
+
+# The support headers are located where this script is.
+SELFPATH=`echo $0 | sed -n '/\//{s/\/find_flags//;p;}'`
+if test "x$SELFPATH" = "x" ; then SELFPATH="." ; fi
+SELFPATH=`cd "$SELFPATH" ; pwd`
+
+INCLUDES="-iwrapper\"$SELFPATH\" $INCLUDES"
+
+# Format and print out the options.
+OPTIONS="$MACROS -D_WCHAR_T $INCLUDES"
+echo $OPTIONS
Modified: gccxml_bin/v09/win32/share/gccxml-0.9/MIPSpro/find_flags
===================================================================
--- gccxml_bin/v09/win32/share/gccxml-0.9/MIPSpro/find_flags 2008-12-21 22:28:17 UTC (rev 1483)
+++ gccxml_bin/v09/win32/share/gccxml-0.9/MIPSpro/find_flags 2008-12-22 22:11:51 UTC (rev 1484)
@@ -1,137 +1,137 @@
-#!/bin/sh
-#=============================================================================
-#
-# Program: GCC-XML
-# Module: $RCSfile: find_flags,v $
-# Language: C++
-# Date: $Date: 2005/08/01 22:11:33 $
-# Version: $Revision: 1.5 $
-#
-# Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
-# See Copyright.txt for details.
-#
-# This software is distributed WITHOUT ANY WARRANTY; without even
-# the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
-# PURPOSE. See the above copyright notices for more information.
-#
-#=============================================================================
-
-# Find the MIPSPro executable name.
-if test "x$1" = "x" ; then
- if test "x${CXX}" = "x" ; then
- CXX=CC
- fi
-else
- CXX="$1"
- shift
- CXXFLAGS="$@"
-fi
-
-GCCXML_PID="$$"
-TESTFILE="find_flags_temp$GCCXML_PID"
-
-# Construct a test input file that checks for some builtin definitions
-# in the compiler that are not displayed by the -v option. This list
-# was obtained by running "strings /usr/lib32/cmplrs/fecc" and testing
-# for definitions with a giant version of the string below.
-echo "
-#ifdef _BOOL
-D_BOOL _BOOL
-#endif
-#ifdef _EXPLICIT_IS_KEYWORD
-D_EXPLICIT_IS_KEYWORD _EXPLICIT_IS_KEYWORD
-#endif
-#ifdef _LIBC_IN_NAMESPACE_STD_
-D_LIBC_IN_NAMESPACE_STD_ _LIBC_IN_NAMESPACE_STD_
-#endif
-#ifdef _MEMBER_TEMPLATES
-D_MEMBER_TEMPLATES _MEMBER_TEMPLATES
-#endif
-#ifdef _MUTABLE_IS_KEYWORD
-D_MUTABLE_IS_KEYWORD _MUTABLE_IS_KEYWORD
-#endif
-#ifdef _NAMESPACES
-D_NAMESPACES _NAMESPACES
-#endif
-#ifdef _PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES
-D_PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES _PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES
-#endif
-#ifdef _STANDARD_C_PLUS_PLUS
-D_STANDARD_C_PLUS_PLUS _STANDARD_C_PLUS_PLUS
-#endif
-#ifdef _TYPENAME_IS_KEYWORD
-D_TYPENAME_IS_KEYWORD _TYPENAME_IS_KEYWORD
-#endif
-#ifdef _WCHAR_T
-D_WCHAR_T _WCHAR_T
-#endif
-#ifdef _WCHAR_T_IS_KEYWORD
-D_WCHAR_T_IS_KEYWORD _WCHAR_T_IS_KEYWORD
-#endif
-#ifdef __ANSI_CPP__
-D__ANSI_CPP__ __ANSI_CPP__
-#endif
-#ifdef __ARRAY_OPERATORS
-D__ARRAY_OPERATORS __ARRAY_OPERATORS
-#endif
-#ifdef __EDG_ABI_COMPATIBILITY_VERSION
-D__EDG_ABI_COMPATIBILITY_VERSION __EDG_ABI_COMPATIBILITY_VERSION
-#endif
-#ifdef __EDG_RUNTIME_USES_NAMESPACES
-D__EDG_RUNTIME_USES_NAMESPACES __EDG_RUNTIME_USES_NAMESPACES
-#endif
-#ifdef __EDG_VERSION__
-D__EDG_VERSION__ __EDG_VERSION__
-#endif
-#ifdef __EDG__
-D__EDG__ __EDG__
-#endif
-#ifdef __EXCEPTIONS
-D__EXCEPTIONS __EXCEPTIONS
-#endif
-#ifdef __LIBC_MATH_OVERLOAD__
-D__LIBC_MATH_OVERLOAD__ __LIBC_MATH_OVERLOAD__
-#endif
-#ifdef __RTTI
-D__RTTI __RTTI
-#endif
-#ifdef __STDC__
-D__STDC__ __STDC__
-#endif
-" > /tmp/$TESTFILE.cxx
-
-# Find the macro definition options.
-MACROS=`
-${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
-sed -n '/_COMPILER_VERSION/{s/ \/tmp\/'$TESTFILE'.cxx.*$//
-s/ -/\\
--/g;p;}' |
-sed -n '/^-D.*$/{s/-D\([^=]*\)=\([^ ]\{1,\} .*\)/-D\1='\''\2'\''/;p;}' |
-sed -n 'H;${g;s/\n/ /g;p;}'`
-
-# Find the internally defined macros.
-LANGSTD=`
-${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
-sed -n '/^D/ {s/^D/-D/;s/ /=/;p;}' |
-sed -n 'H;${g;s/\n/ /g;p;}'`
-
-# Find the include path options.
-INCLUDES=`
-${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
-sed -n '/_COMPILER_VERSION/{s/ \/tmp\/'$TESTFILE'.cxx.*$//
-s/ -/\\
--/g;p;}' |
-sed -n '/^-I.*$/{p;}' |
-sed -n 'H;${g;s/\n/ /g;p;}'`
-
-# The support headers are located where this script is.
-SELFPATH=`echo $0 | sed -n '/\//{s/\/find_flags//;p;}'`
-if test "x$SELFPATH" = "x" ; then SELFPATH="." ; fi
-SELFPATH=`cd "$SELFPATH" ; pwd`
-INCLUDES="-iwrapper\"$SELFPATH/7.3\" $INCLUDES"
-
-rm -f /tmp/$TESTFILE.cxx
-
-# Format and print out the options.
-OPTIONS="$MACROS $LANGSTD $INCLUDES"
-echo $OPTIONS
+#!/bin/sh
+#=============================================================================
+#
+# Program: GCC-XML
+# Module: $RCSfile: find_flags,v $
+# Language: C++
+# Date: $Date: 2005-08-01 22:11:33 $
+# Version: $Revision: 1.5 $
+#
+# Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
+# See Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even
+# the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+# PURPOSE. See the above copyright notices for more information.
+#
+#=============================================================================
+
+# Find the MIPSPro executable name.
+if test "x$1" = "x" ; then
+ if test "x${CXX}" = "x" ; then
+ CXX=CC
+ fi
+else
+ CXX="$1"
+ shift
+ CXXFLAGS="$@"
+fi
+
+GCCXML_PID="$$"
+TESTFILE="find_flags_temp$GCCXML_PID"
+
+# Construct a test input file that checks for some builtin definitions
+# in the compiler that are not displayed by the -v option. This list
+# was obtained by running "strings /usr/lib32/cmplrs/fecc" and testing
+# for definitions with a giant version of the string below.
+echo "
+#ifdef _BOOL
+D_BOOL _BOOL
+#endif
+#ifdef _EXPLICIT_IS_KEYWORD
+D_EXPLICIT_IS_KEYWORD _EXPLICIT_IS_KEYWORD
+#endif
+#ifdef _LIBC_IN_NAMESPACE_STD_
+D_LIBC_IN_NAMESPACE_STD_ _LIBC_IN_NAMESPACE_STD_
+#endif
+#ifdef _MEMBER_TEMPLATES
+D_MEMBER_TEMPLATES _MEMBER_TEMPLATES
+#endif
+#ifdef _MUTABLE_IS_KEYWORD
+D_MUTABLE_IS_KEYWORD _MUTABLE_IS_KEYWORD
+#endif
+#ifdef _NAMESPACES
+D_NAMESPACES _NAMESPACES
+#endif
+#ifdef _PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES
+D_PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES _PARTIAL_SPECIALIZATION_OF_CLASS_TEMPLATES
+#endif
+#ifdef _STANDARD_C_PLUS_PLUS
+D_STANDARD_C_PLUS_PLUS _STANDARD_C_PLUS_PLUS
+#endif
+#ifdef _TYPENAME_IS_KEYWORD
+D_TYPENAME_IS_KEYWORD _TYPENAME_IS_KEYWORD
+#endif
+#ifdef _WCHAR_T
+D_WCHAR_T _WCHAR_T
+#endif
+#ifdef _WCHAR_T_IS_KEYWORD
+D_WCHAR_T_IS_KEYWORD _WCHAR_T_IS_KEYWORD
+#endif
+#ifdef __ANSI_CPP__
+D__ANSI_CPP__ __ANSI_CPP__
+#endif
+#ifdef __ARRAY_OPERATORS
+D__ARRAY_OPERATORS __ARRAY_OPERATORS
+#endif
+#ifdef __EDG_ABI_COMPATIBILITY_VERSION
+D__EDG_ABI_COMPATIBILITY_VERSION __EDG_ABI_COMPATIBILITY_VERSION
+#endif
+#ifdef __EDG_RUNTIME_USES_NAMESPACES
+D__EDG_RUNTIME_USES_NAMESPACES __EDG_RUNTIME_USES_NAMESPACES
+#endif
+#ifdef __EDG_VERSION__
+D__EDG_VERSION__ __EDG_VERSION__
+#endif
+#ifdef __EDG__
+D__EDG__ __EDG__
+#endif
+#ifdef __EXCEPTIONS
+D__EXCEPTIONS __EXCEPTIONS
+#endif
+#ifdef __LIBC_MATH_OVERLOAD__
+D__LIBC_MATH_OVERLOAD__ __LIBC_MATH_OVERLOAD__
+#endif
+#ifdef __RTTI
+D__RTTI __RTTI
+#endif
+#ifdef __STDC__
+D__STDC__ __STDC__
+#endif
+" > /tmp/$TESTFILE.cxx
+
+# Find the macro definition options.
+MACROS=`
+${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
+sed -n '/_COMPILER_VERSION/{s/ \/tmp\/'$TESTFILE'.cxx.*$//
+s/ -/\\
+-/g;p;}' |
+sed -n '/^-D.*$/{s/-D\([^=]*\)=\([^ ]\{1,\} .*\)/-D\1='\''\2'\''/;p;}' |
+sed -n 'H;${g;s/\n/ /g;p;}'`
+
+# Find the internally defined macros.
+LANGSTD=`
+${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
+sed -n '/^D/ {s/^D/-D/;s/ /=/;p;}' |
+sed -n 'H;${g;s/\n/ /g;p;}'`
+
+# Find the include path options.
+INCLUDES=`
+${CXX} ${CXXFLAGS} -E -v /tmp/$TESTFILE.cxx 2>&1 |
+sed -n '/_COMPILER_VERSION/{s/ \/tmp\/'$TESTFILE'.cxx.*$//
+s/ -/\\
+-/g;p;}' |
+sed -n '/^-I.*$/{p;}' |
+sed -n 'H;${g;s/\n/ /g;p;}'`
+
+# The support headers are located where this script is.
+SELFPATH=`echo $0 | sed -n '/\//{s/\/find_flags//;p;}'`
+if test "x$SELFPATH" = "x" ; then SELFPATH="." ; fi
+SELFPATH=`cd "$SELFPATH" ; pwd`
+INCLUDES="-iwrapper\"$SELFPATH/7.3\" $INCLUDES"
+
+rm -f /tmp/$TESTFILE.cxx
+
+# Format and print out the options.
+OPTIONS="$MACROS $LANGSTD $INCLUDES"
+echo $OPTIONS
Added: gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/CodeAnalysis/sourceannotations.h
===================================================================
--- gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/CodeAnalysis/sourceannotations.h (rev 0)
+++ gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/CodeAnalysis/sourceannotations.h 2008-12-22 22:11:51 UTC (rev 1484)
@@ -0,0 +1,289 @@
+#if _MSC_VER >= 1400
+
+#pragma once
+
+#ifndef _M_CEE_SAFE // Source annotation attributes don't work with /clr:safe
+
+#if !defined(_W64)
+#if !defined(__midl) && (defined(_X86_) || defined(_M_IX86)) && _MSC_VER >= 1300
+#define _W64 __w64
+#else
+#define _W64
+#endif
+#endif
+
+#ifndef _SIZE_T_DEFINED
+#ifdef _WIN64
+typedef unsigned __int64 size_t;
+#else
+typedef _W64 unsigned int size_t;
+#endif
+#define _SIZE_T_DEFINED
+#endif
+
+#ifndef _WCHAR_T_DEFINED
+typedef unsigned short wchar_t;
+#define _WCHAR_T_DEFINED
+#endif
+
+
+#pragma push_macro( "SA" )
+#pragma push_macro( "REPEATABLE" )
+
+#ifdef __cplusplus
+#define SA( id ) id
+#define REPEATABLE
+#else // !__cplusplus
+#define SA( id ) SA_##id
+#define REPEATABLE
+#endif // !__cplusplus
+
+#ifdef __cplusplus
+namespace vc_attributes
+{
+#endif // __cplusplus
+
+enum SA( YesNoMaybe )
+{
+ // Choose values that we can detect as invalid if they are or'd together
+ SA( No ) = 0x0fff0001,
+ SA( Maybe ) = 0x0fff0010,
+ SA( Yes ) = 0x0fff0100
+};
+
+typedef enum SA( YesNoMaybe ) SA( YesNoMaybe );
+
+enum SA( AccessType )
+{
+ SA( NoAccess ) = 0,
+ SA( Read ) = 1,
+ SA( Write ) = 2,
+ SA( ReadWrite ) = 3
+};
+
+typedef enum SA( AccessType ) SA( AccessType );
+
+#ifndef SAL_NO_ATTRIBUTE_DECLARATIONS
+
+REPEATABLE
+struct PreAttribute
+{
+#ifdef __cplusplus
+ PreAttribute();
+#endif
+
+ unsigned int Deref;
+ SA( YesNoMaybe ) Valid;
+ SA( YesNoMaybe ) Null;
+ SA( YesNoMaybe ) Tainted;
+ SA( AccessType ) Access;
+ size_t ValidElementsConst;
+ size_t ValidBytesConst;
+ const wchar_t* ValidElements;
+ const wchar_t* ValidBytes;
+ const wchar_t* ValidElementsLength;
+ const wchar_t* ValidBytesLength;
+ size_t WritableElementsConst;
+ size_t WritableBytesConst;
+ const wchar_t* WritableElements;
+ const wchar_t* WritableBytes;
+ const wchar_t* WritableElementsLength;
+ const wchar_t* WritableBytesLength;
+ size_t ElementSizeConst;
+ const wchar_t* ElementSize;
+ SA( YesNoMaybe ) NullTerminated;
+ const wchar_t* Condition;
+};
+
+REPEATABLE
+struct PostAttribute
+{
+#ifdef __cplusplus
+ PostAttribute();
+#endif
+
+ unsigned int Deref;
+ SA( YesNoMaybe ) Valid;
+ SA( YesNoMaybe ) Null;
+ SA( YesNoMaybe ) Tainted;
+ SA( AccessType ) Access;
+ size_t ValidElementsConst;
+ size_t ValidBytesConst;
+ const wchar_t* ValidElements;
+ const wchar_t* ValidBytes;
+ const wchar_t* ValidElementsLength;
+ const wchar_t* ValidBytesLength;
+ size_t WritableElementsConst;
+ size_t WritableBytesConst;
+ const wchar_t* WritableElements;
+ const wchar_t* WritableBytes;
+ const wchar_t* WritableElementsLength;
+ const wchar_t* WritableBytesLength;
+ size_t ElementSizeConst;
+ const wchar_t* ElementSize;
+ SA( YesNoMaybe ) NullTerminated;
+ SA( YesNoMaybe ) MustCheck;
+ const wchar_t* Condition;
+};
+
+struct FormatStringAttribute
+{
+#ifdef __cplusplus
+ FormatStringAttribute();
+#endif
+
+ const wchar_t* Style;
+ const wchar_t* UnformattedAlternative;
+};
+
+REPEATABLE
+struct InvalidCheckAttribute
+{
+#ifdef __cplusplus
+ InvalidCheckAttribute();
+#endif
+
+ long Value;
+};
+
+struct SuccessAttribute
+{
+#ifdef __cplusplus
+ SuccessAttribute();
+#endif
+
+ const wchar_t* Condition;
+};
+
+REPEATABLE
+struct PreBoundAttribute
+{
+#ifdef __cplusplus
+ PreBoundAttribute();
+#endif
+ unsigned int Deref;
+};
+
+REPEATABLE
+struct PostBoundAttribute
+{
+#ifdef __cplusplus
+ PostBoundAttribute();
+#endif
+ unsigned int Deref;
+};
+
+REPEATABLE
+struct PreRangeAttribute
+{
+#ifdef __cplusplus
+ PreRangeAttribute();
+#endif
+ unsigned int Deref;
+ const char* MinVal;
+ const char* MaxVal;
+};
+
+REPEATABLE
+struct PostRangeAttribute
+{
+#ifdef __cplusplus
+ PostRangeAttribute();
+#endif
+ unsigned int Deref;
+ const char* MinVal;
+ const char* MaxVal;
+};
+
+#endif // !SAL_NO_ATTRIBUTE_DECLARATIONS
+
+#ifdef __cplusplus
+}; // namespace vc_attributes
+#endif // __cplusplus
+
+#pragma pop_macro( "REPEATABLE" )
+#pragma pop_macro( "SA" )
+
+#ifdef __cplusplus
+
+#define SA_All All
+#define SA_Class Class
+#define SA_Constructor Constructor
+#define SA_Delegate Delegate
+#define SA_Enum Enum
+#define SA_Event Event
+#define SA_Field Field
+#define SA_GenericParameter GenericParameter
+#define SA_Interface Interface
+#define SA_Method Method
+#define SA_Module Module
+#define SA_Parameter Parameter
+#define SA_Property Property
+#define SA_ReturnValue ReturnValue
+#define SA_Struct Struct
+
+typedef ::vc_attributes::YesNoMaybe SA_YesNoMaybe;
+const ::vc_attributes::YesNoMaybe SA_Yes = ::vc_attributes::Yes;
+const ::vc_attributes::YesNoMaybe SA_No = ::vc_attributes::No;
+const ::vc_attributes::YesNoMaybe SA_Maybe = ::vc_attributes::Maybe;
+
+typedef ::vc_attributes::AccessType SA_AccessType;
+const ::vc_attributes::AccessType SA_NoAccess = ::vc_attributes::NoAccess;
+const ::vc_attributes::AccessType SA_Read = ::vc_attributes::Read;
+const ::vc_attributes::AccessType SA_Write = ::vc_attributes::Write;
+const ::vc_attributes::AccessType SA_ReadWrite = ::vc_attributes::ReadWrite;
+
+#ifndef SAL_NO_ATTRIBUTE_DECLARATIONS
+typedef ::vc_attributes::PreAttribute SA_Pre;
+typedef ::vc_attributes::PostAttribute SA_Post;
+typedef ::vc_attributes::FormatStringAttribute SA_FormatString;
+typedef ::vc_attributes::InvalidCheckAttribute SA_InvalidCheck; /*???*/
+typedef ::vc_attributes::SuccessAttribute SA_Success;
+typedef ::vc_attributes::PreBoundAttribute SA_PreBound;
+typedef ::vc_attributes::PostBoundAttribute SA_PostBound;
+typedef ::vc_attributes::PreRangeAttribute SA_PreRange;
+typedef ::vc_attributes::PostRangeAttribute SA_PostRange;
+#endif //!SAL_NO_ATTRIBUTE_DECLARATIONS
+
+#else // !__cplusplus
+
+typedef struct PreAttribute SA_Pre;
+typedef struct PreAttribute PreAttribute;
+typedef struct PostAttribute SA_Post;
+typedef struct PostAttribute PostAttribute;
+typedef struct FormatStringAttribute SA_FormatString;
+typedef struct InvalidCheckAttribute SA_InvalidCheck; /*???*/
+typedef struct SuccessAttribute SA_Success;
+typedef struct PreBoundAttribute SA_PreBound;
+typedef struct PostBoundAttribute SA_PostBound;
+typedef struct PreRangeAttribute SA_PreRange;
+typedef struct PostRangeAttribute SA_PostRange;
+
+#endif // __cplusplus
+
+#endif // !_M_CEE_SAFE
+
+#ifdef _MANAGED
+
+#ifdef CODE_ANALYSIS
+#define SA_SUPPRESS_MESSAGE( category, id, ... ) [::System::Diagnostics::CodeAnalysis::SuppressMessage( category, id, __VA_ARGS__ )]
+#define CA_SUPPRESS_MESSAGE( ... ) [System::Diagnostics::CodeAnalysis::SuppressMessage( __VA_ARGS__ )]
+#define CA_GLOBAL_SUPPRESS_MESSAGE( ... ) [assembly:System::Diagnostics::CodeAnalysis::SuppressMessage( __VA_ARGS__ )]
+#else // !CODE_ANALYSIS
+#define SA_SUPPRESS_MESSAGE( category, id, ... )
+#define CA_SUPPRESS_MESSAGE( ... )
+#define CA_GLOBAL_SUPPRESS_MESSAGE( ... )
+#endif // !CODE_ANALYSIS
+
+#endif // _MANAGED
+
+// Windows SDK Update Vista Beta2 (June 2006): __analysis_assume defined by specstrings.h
+#ifdef _PREFAST_
+// #define __analysis_assume(expr) __assume(expr)
+#else // !_PREFAST_
+// #define __analysis_assume(expr)
+#endif // _PREFAST_
+
+
+#endif // _MSC_VER >= 1400
+
Added: gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/algorithm
===================================================================
--- gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/algorithm (rev 0)
+++ gccxml_bin/v09/win32/share/gccxml-0.9/Vc9/Include/algorithm 2008-12-22 22:11:51 UTC (rev 1484)
@@ -0,0 +1,5832 @@
+// algorithm standard header
+#pragma once
+#ifndef _ALGORITHM_
+#define _ALGORITHM_
+#ifndef RC_INVOKED
+#include <memory>
+
+#ifdef _MSC_VER
+ #pragma pack(push,_CRT_PACKING)
+ #pragma warning(push,3)
+ #pragma warning(disable: 4244)
+#endif /* _MSC_VER */
+
+/* ------------------------------------------------------------------------ */
+/* Forward declare these now because they are used as non-dependent names. */
+_STDEXT_BEGIN
+template<class _InIt, class _OutIt, class _Ty>
+inline _OutIt unchecked_remove_copy(_InIt _First, _InIt _Last,
+ _OutIt _Dest, const _Ty& _Val);
+template<class _InIt, class _OutIt, class _Pr>
+inline _OutIt unchecked_remove_copy_if(_InIt _First, _InIt _Last,
+ _OutIt _Dest, _Pr _Pred);
+template<class _InIt1, class _InIt2, class _OutIt>
+inline _OutIt unchecked_merge(_InIt1 _First1, _InIt1 _Last1,
+ _InIt2 _First2, _InIt2 _Last2, _OutIt _Dest);
+template<class _InIt1, class _InIt2, class _OutIt, class _Pr>
+inline _OutIt unchecked_merge(_InIt1 _First1, _InIt1 _Last1,
+ _InIt2 _First2, _InIt2 _Last2, _OutIt _Dest,
+ _Pr _Pred);
+template<class _BidIt1, class _BidIt2, class _BidIt3>
+inline _BidIt3 _Unchecked_merge_backward(_BidIt1 _First1, _BidIt1 _Last1,
+ _BidIt2 _First2, _BidIt2 _Last2,
+ _BidIt3 _Dest);
+template<class _BidIt1, class _BidIt2, class _BidIt3, class _Pr>
+inline _BidIt3 _Unchecked_merge_backward(_BidIt1 _First1, _BidIt1 _Last1,
+ _BidIt2 _First2, _BidIt2 _Last2,
+ _BidIt3 _Dest, _Pr _Pred);
+template<class _BidIt, class _OutIt, class _Diff>
+inline void _Unchecked_chunked_merge(_BidIt _First, _BidIt _Last,
+ _OutIt _Dest, _Diff _Chunk,
+ _Diff _Count);
+template<class _BidIt, class _OutIt, class _Diff, class _Pr>
+inline void _Unchecked_chunked_merge(_BidIt _First, _BidIt _Last,
+ _OutIt _Dest, _Diff _Chunk,
+ _Diff _Count, _Pr _Pred);
+_STDEXT_END
+/* ------------------------------------------------------------------------ */
+
+_STD_BEGIN
+
+ // COMMON SORT PARAMETERS
+const int _ISORT_MAX = 32; // maximum size for insertion sort
+
+ // TEMPLATE FUNCTION for_each
+template<class _InIt,
+ class _Fn1> inline
+ _Fn1 for_each(_InIt _First, _InIt _Last, _Fn1 _Func)
+ { // perform function for each element
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Func);
+ _CHECKED_BASE_TYPE(_InIt) _ChkFirst(_CHECKED_BASE(_First));
+ _CHECKED_BASE_TYPE(_InIt) _ChkLast(_CHECKED_BASE(_Last));
+ for (; _ChkFirst != _ChkLast; ++_ChkFirst)
+ _Func(*_ChkFirst);
+ return (_Func);
+ }
+
+ // TEMPLATE FUNCTION find
+template<class _InIt, class _Ty>
+inline
+ _InIt _Find(_InIt _First, _InIt _Last, const _Ty& _Val)
+ { // find first matching _Val
+ _DEBUG_RANGE(_First, _Last);
+ for (; _First != _Last; ++_First)
+ if (*_First == _Val)
+ break;
+ return (_First);
+ }
+
+inline const char *_Find(const char *_First, const char *_Last, int _Val)
+ { // find first char that matches _Val
+ _DEBUG_RANGE(_First, _Last);
+ _First = (const char *)::memchr(_First, _Val, _Last - _First);
+ return (_First == 0 ? _Last : _First);
+ }
+
+inline const signed char *_Find(const signed char *_First,
+ const signed char *_Last, int _Val)
+ { // find first signed char that matches _Val
+ _DEBUG_RANGE(_First, _Last);
+ _First = (const signed char *)::memchr(_First, _Val,
+ _Last - _First);
+ return (_First == 0 ? _Last : _First);
+ }
+
+inline const unsigned char *_Find(const unsigned char *_First,
+ const unsigned char *_Last, int _Val)
+ { // find first unsigned char that matches _Val
+ _DEBUG_RANGE(_First, _Last);
+ _First = (const unsigned char *)::memchr(_First, _Val,
+ _Last - _First);
+ return (_First == 0 ? _Last : _First);
+ }
+
+template<class _InIt, class _Ty>
+inline
+ _InIt find(_InIt _First, _InIt _Last, const _Ty& _Val)
+ { // find first matching _Val
+ _ASSIGN_FROM_BASE(_First,
+ _Find(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Val));
+ return (_First);
+ }
+
+ // TEMPLATE FUNCTION find_if
+template<class _InIt,
+ class _Pr> inline
+ _InIt _Find_if(_InIt _First, _InIt _Last, _Pr _Pred)
+ { // find first satisfying _Pred
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Pred);
+ for (; _First != _Last; ++_First)
+ if (_Pred(*_First))
+ break;
+ return (_First);
+ }
+
+template<class _InIt,
+ class _Pr> inline
+ _InIt find_if(_InIt _First, _InIt _Last, _Pr _Pred)
+ { // find first satisfying _Pred
+ _ASSIGN_FROM_BASE(_First,
+ _Find_if(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Pred));
+ return (_First);
+ }
+
+ // TEMPLATE FUNCTION adjacent_find
+template<class _FwdIt> inline
+ _FwdIt _Adjacent_find(_FwdIt _First, _FwdIt _Last)
+ { // find first matching successor
+ _DEBUG_RANGE(_First, _Last);
+ for (_FwdIt _Firstb; (_Firstb = _First) != _Last && ++_First != _Last; )
+ if (*_Firstb == *_First)
+ return (_Firstb);
+ return (_Last);
+ }
+
+template<class _FwdIt> inline
+ _FwdIt adjacent_find(_FwdIt _First, _FwdIt _Last)
+ { // find first matching successor
+ _ASSIGN_FROM_BASE(_First,
+ _Adjacent_find(_CHECKED_BASE(_First), _CHECKED_BASE(_Last)));
+ return (_First);
+ }
+
+ // TEMPLATE FUNCTION adjacent_find WITH PRED
+template<class _FwdIt,
+ class _Pr> inline
+ _FwdIt _Adjacent_find(_FwdIt _First, _FwdIt _Last, _Pr _Pred)
+ { // find first satisfying _Pred with successor
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Pred);
+ for (_FwdIt _Firstb; (_Firstb = _First) != _Last && ++_First != _Last; )
+ if (_Pred(*_Firstb, *_First))
+ return (_Firstb);
+ return (_Last);
+ }
+
+template<class _FwdIt,
+ class _Pr> inline
+ _FwdIt adjacent_find(_FwdIt _First, _FwdIt _Last, _Pr _Pred)
+ { // find first satisfying _Pred with successor
+ _ASSIGN_FROM_BASE(_First,
+ _Adjacent_find(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Pred));
+ return (_First);
+ }
+
+ // TEMPLATE FUNCTION count
+template<class _InIt,
+ class _Ty> inline
+ typename iterator_traits<_InIt>::difference_type
+ _Count(_InIt _First, _InIt _Last, const _Ty& _Val)
+ { // count elements that match _Val
+ _DEBUG_RANGE(_First, _Last);
+ typename iterator_traits<_InIt>::difference_type _Cnt = 0;
+
+ for (; _First != _Last; ++_First)
+ if (*_First == _Val)
+ ++_Cnt;
+ return (_Cnt);
+ }
+
+template<class _InIt,
+ class _Ty> inline
+ typename iterator_traits<_InIt>::difference_type
+ count(_InIt _First, _InIt _Last, const _Ty& _Val)
+ { // count elements that match _Val
+ return _Count(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Val);
+ }
+
+ // TEMPLATE FUNCTION count_if
+template<class _InIt,
+ class _Pr> inline
+ typename iterator_traits<_InIt>::difference_type
+ _Count_if(_InIt _First, _InIt _Last, _Pr _Pred)
+ { // count elements satisfying _Pred
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Pred);
+ typename iterator_traits<_InIt>::difference_type _Count = 0;
+
+ for (; _First != _Last; ++_First)
+ if (_Pred(*_First))
+ ++_Count;
+ return (_Count);
+ }
+
+template<class _InIt,
+ class _Pr> inline
+ typename iterator_traits<_InIt>::difference_type
+ count_if(_InIt _First, _InIt _Last, _Pr _Pred)
+ { // count elements satisfying _Pred
+ return _Count_if(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Pred);
+ }
+
+ // TEMPLATE FUNCTION search
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Diff1,
+ class _Diff2> inline
+ _FwdIt1 _Search(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Diff1 *, _Diff2 *)
+ { // find first [_First2, _Last2) match
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ _Diff1 _Count1 = 0;
+ _Distance(_First1, _Last1, _Count1);
+ _Diff2 _Count2 = 0;
+ _Distance(_First2, _Last2, _Count2);
+
+ for (; _Count2 <= _Count1; ++_First1, --_Count1)
+ { // room for match, try it
+ _FwdIt1 _Mid1 = _First1;
+ for (_FwdIt2 _Mid2 = _First2; ; ++_Mid1, ++_Mid2)
+ if (_Mid2 == _Last2)
+ return (_First1);
+ else if (!(*_Mid1 == *_Mid2))
+ break;
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2> inline
+ _FwdIt1 search(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2)
+ { // find first [_First2, _Last2) match
+ _ASSIGN_FROM_BASE(_First1,
+ _Search(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2),
+ _Dist_type(_First1), _Dist_type(_First2)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION search WITH PRED
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Diff1,
+ class _Diff2,
+ class _Pr> inline
+ _FwdIt1 _Search(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred, _Diff1 *, _Diff2 *)
+ { // find first [_First2, _Last2) satisfying _Pred
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ _DEBUG_POINTER(_Pred);
+ _Diff1 _Count1 = 0;
+ _Distance(_First1, _Last1, _Count1);
+ _Diff2 _Count2 = 0;
+ _Distance(_First2, _Last2, _Count2);
+
+ for (; _Count2 <= _Count1; ++_First1, --_Count1)
+ { // room for match, try it
+ _FwdIt1 _Mid1 = _First1;
+ for (_FwdIt2 _Mid2 = _First2; ; ++_Mid1, ++_Mid2)
+ if (_Mid2 == _Last2)
+ return (_First1);
+ else if (!_Pred(*_Mid1, *_Mid2))
+ break;
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Pr> inline
+ _FwdIt1 search(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred)
+ { // find first [_First2, _Last2) satisfying _Pred
+ _ASSIGN_FROM_BASE(_First1,
+ _Search(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2), _Pred,
+ _Dist_type(_First1), _Dist_type(_First2)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION search_n
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty> inline
+ _FwdIt1 _Search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val, forward_iterator_tag)
+ { // find first _Count * _Val match, forward iterators
+ _DEBUG_RANGE(_First1, _Last1);
+
+ if (_Count <= 0)
+ return (_First1);
+
+ for (; _First1 != _Last1; ++_First1)
+ if (*_First1 == _Val)
+ { // found start of possible match, check it out
+ _FwdIt1 _Mid1 = _First1;
+
+ for (_Diff2 _Count1 = _Count; ; )
+ if (--_Count1 == 0)
+ return (_First1); // found rest of match, report it
+ else if (++_Mid1 == _Last1)
+ return (_Last1); // short match at end
+ else if (!(*_Mid1 == _Val))
+ break; // short match not at end
+
+ _First1 = _Mid1; // pick up just beyond failed match
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty> inline
+ _FwdIt1 _Search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val, random_access_iterator_tag)
+ { // find first _Count * _Val match, random-access iterators
+ _DEBUG_RANGE(_First1, _Last1);
+
+ if (_Count <= 0)
+ return (_First1);
+
+ _FwdIt1 _Oldfirst1 = _First1;
+ for (_Diff2 _Inc = 0; _Count <= _Last1 - _Oldfirst1; )
+ { // enough room, look for a match
+ _First1 = _Oldfirst1 + _Inc;
+ if (*_First1 == _Val)
+ { // found part of possible match, check it out
+ _Diff2 _Count1 = _Count;
+ _FwdIt1 _Mid1 = _First1;
+
+ for (; _Oldfirst1 != _First1 && _First1[-1] == _Val; --_First1)
+ --_Count1; // back up over any skipped prefix
+
+ if (_Count1 <= _Last1 - _Mid1)
+ for (; ; ) // enough left, test suffix
+ if (--_Count1 == 0)
+ return (_First1); // found rest of match, report it
+ else if (!(*++_Mid1 == _Val))
+ break; // short match not at end
+
+ _Oldfirst1 = ++_Mid1; // failed match, take small jump
+ _Inc = 0;
+ }
+ else
+ { // no match, take big jump and back up as needed
+ _Oldfirst1 = _First1 + 1;
+ _Inc = _Count - 1;
+ }
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty> inline
+ _FwdIt1 search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val)
+ { // find first _Count * _Val match
+ _ASSIGN_FROM_BASE(_First1,
+ _Search_n(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _Count, _Val,
+ _Iter_cat(_First1)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION search_n WITH PRED
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty,
+ class _Pr> inline
+ _FwdIt1 _Search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val, _Pr _Pred, forward_iterator_tag)
+ { // find first _Count * _Val satisfying _Pred, forward iterators
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_POINTER(_Pred);
+
+ if (_Count <= 0)
+ return (_First1);
+
+ for (; _First1 != _Last1; ++_First1)
+ if (_Pred(*_First1, _Val))
+ { // found start of possible match, check it out
+ _FwdIt1 _Mid1 = _First1;
+
+ for (_Diff2 _Count1 = _Count; ; )
+ if (--_Count1 == 0)
+ return (_First1); // found rest of match, report it
+ else if (++_Mid1 == _Last1)
+ return (_Last1); // short match at end
+ else if (!_Pred(*_Mid1, _Val))
+ break; // short match not at end
+
+ _First1 = _Mid1; // pick up just beyond failed match
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty,
+ class _Pr> inline
+ _FwdIt1 _Search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val, _Pr _Pred, random_access_iterator_tag)
+ { // find first _Count * _Val satisfying _Pred, random-access iterators
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_POINTER(_Pred);
+
+ if (_Count <= 0)
+ return (_First1);
+
+ _FwdIt1 _Oldfirst1 = _First1;
+ for (; _Count <= _Last1 - _Oldfirst1; )
+ { // enough room, look for a match
+ if (_Pred(*_First1, _Val))
+ { // found part of possible match, check it out
+ _Diff2 _Count1 = _Count;
+ _FwdIt1 _Mid1 = _First1;
+
+ for (; _Oldfirst1 != _First1 && _Pred(_First1[-1], _Val);
+ --_First1)
+ --_Count1; // back up over any skipped prefix
+
+ if (_Count1 <= _Last1 - _Mid1)
+ for (; ; ) // enough left, test suffix
+ if (--_Count1 == 0)
+ return (_First1); // found rest of match, report it
+ else if (!_Pred(*++_Mid1, _Val))
+ break; // short match not at end
+
+ _Oldfirst1 = ++_Mid1; // failed match, take small jump
+ _First1 = _Oldfirst1;
+ }
+ else
+ { // no match, take big jump and back up as needed
+ _Oldfirst1 = _First1 + 1;
+ _First1 += _Count;
+ }
+ }
+ return (_Last1);
+ }
+
+template<class _FwdIt1,
+ class _Diff2,
+ class _Ty,
+ class _Pr> inline
+ _FwdIt1 search_n(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _Diff2 _Count, const _Ty& _Val, _Pr _Pred)
+ { // find first _Count * _Val satisfying _Pred
+ _ASSIGN_FROM_BASE(_First1,
+ _Search_n(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _Count, _Val, _Pred,
+ _Iter_cat(_First1)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION find_end
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Diff1,
+ class _Diff2> inline
+ _FwdIt1 _Find_end(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Diff1 *, _Diff2 *)
+ { // find last [_First2, _Last2) match
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ _Diff1 _Count1 = 0;
+ _Distance(_First1, _Last1, _Count1);
+ _Diff2 _Count2 = 0;
+ _Distance(_First2, _Last2, _Count2);
+ _FwdIt1 _Ans = _Last1;
+
+ if (0 < _Count2)
+ for (; _Count2 <= _Count1; ++_First1, --_Count1)
+ { // room for match, try it
+ _FwdIt1 _Mid1 = _First1;
+ for (_FwdIt2 _Mid2 = _First2; ; ++_Mid1)
+ if (!(*_Mid1 == *_Mid2))
+ break;
+ else if (++_Mid2 == _Last2)
+ { // potential answer, save it
+ _Ans = _First1;
+ break;
+ }
+ }
+ return (_Ans);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2> inline
+ _FwdIt1 find_end(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2)
+ { // find last [_First2, _Last2) match
+ _ASSIGN_FROM_BASE(_First1,
+ _Find_end(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2),
+ _Dist_type(_First1), _Dist_type(_First2)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION find_end WITH PRED
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Diff1,
+ class _Diff2,
+ class _Pr> inline
+ _FwdIt1 _Find_end(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred, _Diff1 *, _Diff2 *)
+ { // find last [_First2, _Last2) satisfying _Pred
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ _DEBUG_POINTER(_Pred);
+ _Diff1 _Count1 = 0;
+ _Distance(_First1, _Last1, _Count1);
+ _Diff2 _Count2 = 0;
+ _Distance(_First2, _Last2, _Count2);
+ _FwdIt1 _Ans = _Last1;
+
+ if (0 < _Count2)
+ for (; _Count2 <= _Count1; ++_First1, --_Count1)
+ { // room for match, try it
+ _FwdIt1 _Mid1 = _First1;
+ for (_FwdIt2 _Mid2 = _First2; ; ++_Mid1)
+ if (!_Pred(*_Mid1, *_Mid2))
+ break;
+ else if (++_Mid2 == _Last2)
+ { // potential answer, save it
+ _Ans = _First1;
+ break;
+ }
+ }
+ return (_Ans);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Pr> inline
+ _FwdIt1 find_end(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred)
+ { // find last [_First2, _Last2) satisfying _Pred
+ _ASSIGN_FROM_BASE(_First1,
+ _Find_end(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2), _Pred,
+ _Dist_type(_First1), _Dist_type(_First2)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION find_first_of
+template<class _FwdIt1,
+ class _FwdIt2> inline
+ _FwdIt1 _Find_first_of(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2)
+ { // look for one of [_First2, _Last2) that matches element
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ for (; _First1 != _Last1; ++_First1)
+ for (_FwdIt2 _Mid2 = _First2; _Mid2 != _Last2; ++_Mid2)
+ if (*_First1 == *_Mid2)
+ return (_First1);
+ return (_First1);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2> inline
+ _FwdIt1 find_first_of(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2)
+ { // look for one of [_First2, _Last2) that matches element
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_RANGE(_First2, _Last2);
+ _ASSIGN_FROM_BASE(_First1,
+ _Find_first_of(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2)));
+ return _First1;
+ }
+
+ // TEMPLATE FUNCTION find_first_of WITH PRED
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Pr> inline
+ _FwdIt1 _Find_first_of(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred)
+ { // look for one of [_First2, _Last2) satisfying _Pred with element
+ _DEBUG_POINTER(_Pred);
+ for (; _First1 != _Last1; ++_First1)
+ for (_FwdIt2 _Mid2 = _First2; _Mid2 != _Last2; ++_Mid2)
+ if (_Pred(*_First1, *_Mid2))
+ return (_First1);
+ return (_First1);
+ }
+
+template<class _FwdIt1,
+ class _FwdIt2,
+ class _Pr> inline
+ _FwdIt1 find_first_of(_FwdIt1 _First1, _FwdIt1 _Last1,
+ _FwdIt2 _First2, _FwdIt2 _Last2, _Pr _Pred)
+ { // look for one of [_First2, _Last2) satisfying _Pred with element
+ _ASSIGN_FROM_BASE(_First1,
+ _Find_first_of(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _CHECKED_BASE(_First2), _CHECKED_BASE(_Last2), _Pred));
+ return (_First1);
+ }
+
+ // TEMPLATE FUNCTION iter_swap
+template<class _FwdIt1,
+ class _FwdIt2> inline
+ void iter_swap(_FwdIt1 _Left, _FwdIt2 _Right)
+ { // swap *_Left and *_Right
+ swap(*_Left, *_Right);
+ }
+
+ // TEMPLATE FUNCTION swap_ranges
+template<class _FwdIt1, class _FwdIt2, class _FwdItCats>
+inline
+ _FwdIt2 _Swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2,
+ _FwdItCats, _Range_checked_iterator_tag)
+ { // swap [_First1, _Last1) with [_First2, ...)
+ _DEBUG_RANGE(_First1, _Last1);
+ for (; _First1 != _Last1; ++_First1, ++_First2)
+ std::iter_swap(_First1, _First2);
+ return (_First2);
+ }
+
+#if _SECURE_SCL
+template<class _FwdIt1, class _FwdIt2>
+inline
+ _FwdIt2 _Swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2,
+ random_access_iterator_tag, _Range_checked_iterator_tag)
+ { // swap [_First1, _Last1) with [_First2, ...)
+ // if _FwdIt2 is range checked, this will make sure there is enough space
+ _FwdIt2 _Result = _First2 + (_Last1 - _First1);
+ _Swap_ranges(_First1, _Last1, _CHECKED_BASE(_First2),
+ forward_iterator_tag(), _Range_checked_iterator_tag());
+ return (_Result);
+ }
+#endif
+
+#if _SECURE_SCL
+
+template<class _FwdIt1, class _FwdIt2>
+inline
+_IF_CHK(_FwdIt2) swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2)
+ {
+ return _Swap_ranges(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2,
+ _Iter_random(_First1, _First2), _STD _Range_checked_iterator_tag());
+ }
+
+template<class _FwdIt1, class _FwdElem2, size_t _Size>
+inline
+_FwdElem2* swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdElem2 (&_First2)[_Size])
+ {
+ return (swap_ranges(_First1, _Last1, _STDEXT make_checked_array_iterator(_First2, _Size)).base());
+ }
+
+template<class _FwdIt1, class _FwdIt2>
+inline
+_SCL_INSECURE_DEPRECATE
+_IF_NOT_CHK(_FwdIt2) swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2)
+ {
+ return _Swap_ranges(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2,
+ _Iter_random(_First1, _First2), _STD _Range_checked_iterator_tag());
+ }
+
+#else
+
+template<class _FwdIt1, class _FwdIt2>
+inline
+ _FwdIt2 swap_ranges(_FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2)
+ {
+ return _Swap_ranges(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2,
+ _Iter_random(_First1, _First2), _STD _Range_checked_iterator_tag());
+ }
+
+#endif
+
+ // TEMPLATE FUNCTION transform WITH UNARY OP
+template<class _InIt, class _OutIt, class _Fn1, class _InOutItCat>
+inline
+ _OutIt _Transform(_InIt _First, _InIt _Last, _OutIt _Dest, _Fn1 _Func,
+ _InOutItCat, _Range_checked_iterator_tag)
+ { // transform [_First, _Last) with _Func
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Dest);
+ _DEBUG_POINTER(_Func);
+ for (; _First != _Last; ++_First, ++_Dest)
+ *_Dest = _Func(*_First);
+ return (_Dest);
+ }
+
+#if _SECURE_SCL
+template<class _InIt, class _OutIt, class _Fn1>
+inline
+ _OutIt _Transform(_InIt _First, _InIt _Last, _OutIt _Dest, _Fn1 _Func,
+ random_access_iterator_tag, _Range_checked_iterator_tag)
+ { // transform [_First, _Last) with _Func
+ // for range checked iterators, this will make sure there is enough space
+ _OutIt _Result = _Dest + (_Last - _First);
+ _Transform(_First, _Last, _CHECKED_BASE(_Dest), _Func,
+ forward_iterator_tag(), _Range_checked_iterator_tag());
+ return (_Result);
+ }
+#endif
+
+#if _SECURE_SCL
+
+template<class _InIt, class _OutIt, class _Fn1>
+inline
+_IF_CHK(_OutIt) transform(_InIt _First, _InIt _Last, _OutIt _Dest, _Fn1 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Dest, _Func,
+ _Iter_random(_First, _Dest), _STD _Range_checked_iterator_tag());
+ }
+
+template<class _InIt, class _OutElem, class _Fn1, size_t _Size>
+inline
+_OutElem* transform(_InIt _First, _InIt _Last, _OutElem (&_Dest)[_Size], _Fn1 _Func)
+ {
+ return (transform(_First, _Last,
+ _STDEXT make_checked_array_iterator(_Dest, _Size), _Func).base());
+ }
+
+template<class _InIt, class _OutIt, class _Fn1>
+inline
+_SCL_INSECURE_DEPRECATE
+_IF_NOT_CHK(_OutIt) transform(_InIt _First, _InIt _Last, _OutIt _Dest, _Fn1 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Dest, _Func,
+ _Iter_random(_First, _Dest), _STD _Range_checked_iterator_tag());
+ }
+
+#else
+
+template<class _InIt, class _OutIt, class _Fn1>
+inline
+ _OutIt transform(_InIt _First, _InIt _Last, _OutIt _Dest, _Fn1 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Dest, _Func,
+ _Iter_random(_First, _Dest), _STD _Range_checked_iterator_tag());
+ }
+
+#endif
+
+ // TEMPLATE FUNCTION transform WITH BINARY OP
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2, class _InItCats, class _InOutItCat>
+inline
+ _OutIt _Transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func,
+ _InItCats, _InOutItCat,
+ _Range_checked_iterator_tag, _Range_checked_iterator_tag)
+ { // transform [_First1, _Last1) and [_First2, _Last2) with _Func
+ _DEBUG_RANGE(_First1, _Last1);
+ _DEBUG_POINTER(_Dest);
+ _DEBUG_POINTER(_Func);
+ for (; _First1 != _Last1; ++_First1, ++_First2, ++_Dest)
+ *_Dest = _Func(*_First1, *_First2);
+ return (_Dest);
+ }
+
+#if _SECURE_SCL
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2>
+inline
+ _OutIt _Transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func,
+ random_access_iterator_tag, random_access_iterator_tag,
+ _Range_checked_iterator_tag, _Range_checked_iterator_tag)
+ { // transform [_First1, _Last1) and [_First2, _Last2) with _Func
+ // for range checked iterators, this will make sure there is enough space
+ _InIt2 _Last2 = _First2 + (_Last1 - _First1); (_Last2);
+ _OutIt _Result = _Dest + (_Last1 - _First1);
+ _Transform(_First1, _Last1, _CHECKED_BASE(_First2),
+ _CHECKED_BASE(_Dest), _Func,
+ forward_iterator_tag(), forward_iterator_tag(),
+ _Range_checked_iterator_tag(), _Range_checked_iterator_tag());
+ return _Result;
+ }
+
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2, class _InOutItCat>
+inline
+ _OutIt _Transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func,
+ random_access_iterator_tag, _InOutItCat,
+ _Range_checked_iterator_tag, _Range_checked_iterator_tag)
+ { // transform [_First1, _Last1) and [_First2, _Last2) with _Func
+ // for range checked iterators, this will make sure there is enough space
+ _InIt2 _Last2 = _First2 + (_Last1 - _First1); (_Last2);
+ return _Transform(_First1, _Last1, _CHECKED_BASE(_First2),
+ _Dest, _Func,
+ forward_iterator_tag(), forward_iterator_tag(),
+ _Range_checked_iterator_tag(), _Range_checked_iterator_tag());
+ }
+
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2, class _InItCats>
+inline
+ _OutIt _Transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func,
+ _InItCats, random_access_iterator_tag,
+ _Range_checked_iterator_tag, _Range_checked_iterator_tag)
+ { // transform [_First1, _Last1) and [_First2, _Last2) with _Func
+ // for range checked iterators, this will make sure there is enough space
+ _OutIt _Result = _Dest + (_Last1 - _First1);
+ _Transform(_First1, _Last1, _First2,
+ _CHECKED_BASE(_Dest), _Func,
+ forward_iterator_tag(), forward_iterator_tag(),
+ _Range_checked_iterator_tag(), _Range_checked_iterator_tag());
+ return _Result;
+ }
+#endif
+
+#if _SECURE_SCL
+
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2>
+inline
+_IF_CHK2_(_InIt2, _OutIt, _OutIt) transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2, _Dest, _Func,
+ _Iter_random(_First1, _First2), _Iter_random(_First1, _Dest),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag());
+ }
+
+template<class _InIt1, class _InElem2, class _OutElem, class _Fn2, size_t _SizeFirst2, size_t _SizeDest>
+inline
+_OutElem* transform(_InIt1 _First1, _InIt1 _Last1, _InElem2 (&_First2)[_SizeFirst2],
+ _OutElem (&_Dest)[_SizeDest], _Fn2 _Func)
+ {
+ return (transform(_First1, _Last1,
+ _STDEXT make_checked_array_iterator(_First2, _SizeFirst2),
+ _STDEXT make_checked_array_iterator(_Dest, _SizeDest),
+ _Func).base());
+ }
+
+template<class _InIt1, class _InIt2, class _OutElem, class _Fn2, size_t _SizeDest>
+inline
+_IF_CHK_(_InIt2, _OutElem*) transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutElem (&_Dest)[_SizeDest], _Fn2 _Func)
+ {
+ return (_Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2,
+ _STDEXT make_checked_array_iterator(_Dest, _SizeDest), _Func,
+ _Iter_random(_First1, _First2), _Iter_cat(_First1),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag()).base());
+ }
+
+template<class _InIt1, class _InIt2, class _OutElem, class _Fn2, size_t _SizeDest>
+inline
+_SCL_INSECURE_DEPRECATE
+_IF_NOT_CHK_(_InIt2, _OutElem*) transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutElem (&_Dest)[_SizeDest], _Fn2 _Func)
+ {
+ return (_Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2,
+ _STDEXT make_checked_array_iterator(_Dest, _SizeDest), _Func,
+ _Iter_random(_First1, _First2), _Iter_cat(_First1),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag()).base());
+ }
+
+template<class _InIt1, class _InElem2, class _OutIt, class _Fn2, size_t _SizeFirst2>
+inline
+_IF_CHK(_OutIt) transform(_InIt1 _First1, _InIt1 _Last1, _InElem2 (&_First2)[_SizeFirst2],
+ _OutIt _Dest, _Fn2 _Func)
+ {
+ return (_Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _STDEXT make_checked_array_iterator(_First2, _SizeFirst2),
+ _Dest, _Func,
+ _Iter_cat(_First1), _Iter_random(_First1, _Dest),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag()));
+ }
+
+template<class _InIt1, class _InElem2, class _OutIt, class _Fn2, size_t _SizeFirst2>
+inline
+_SCL_INSECURE_DEPRECATE
+_IF_NOT_CHK(_OutIt) transform(_InIt1 _First1, _InIt1 _Last1, _InElem2 (&_First2)[_SizeFirst2],
+ _OutIt _Dest, _Fn2 _Func)
+ {
+ return (_Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1),
+ _STDEXT make_checked_array_iterator(_First2, _SizeFirst2),
+ _Dest, _Func,
+ _Iter_cat(_First1), _Iter_random(_First1, _Dest),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag()));
+ }
+
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2>
+inline
+_SCL_INSECURE_DEPRECATE
+_IF_NOT_CHK2_(_InIt2, _OutIt, _OutIt) transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2, _Dest, _Func,
+ _Iter_random(_First1, _First2), _Iter_random(_First1, _Dest),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag());
+ }
+
+#else
+
+template<class _InIt1, class _InIt2, class _OutIt, class _Fn2>
+inline
+ _OutIt transform(_InIt1 _First1, _InIt1 _Last1, _InIt2 _First2,
+ _OutIt _Dest, _Fn2 _Func)
+ {
+ return _Transform(_CHECKED_BASE(_First1), _CHECKED_BASE(_Last1), _First2, _Dest, _Func,
+ _Iter_random(_First1, _First2), _Iter_random(_First1, _Dest),
+ _STD _Range_checked_iterator_tag(), _STD _Range_checked_iterator_tag());
+ }
+
+#endif
+
+ // TEMPLATE FUNCTION replace
+template<class _FwdIt,
+ class _Ty> inline
+ void _Replace(_FwdIt _First, _FwdIt _Last,
+ const _Ty& _Oldval, const _Ty& _Newval)
+ { // replace each matching _Oldval with _Newval
+ _DEBUG_RANGE(_First, _Last);
+ for (; _First != _Last; ++_First)
+ if (*_First == _Oldval)
+ *_First = _Newval;
+ }
+
+template<class _FwdIt,
+ class _Ty> inline
+ void replace(_FwdIt _First, _FwdIt _Last,
+ const _Ty& _Oldval, const _Ty& _Newval)
+ { // replace each matching _Oldval with _Newval
+ _Replace(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Oldval, _Newval);
+ }
+
+ // TEMPLATE FUNCTION replace_if
+template<class _FwdIt,
+ class _Pr,
+ class _Ty> inline
+ void _Replace_if(_FwdIt _First, _FwdIt _Last, _Pr _Pred, const _Ty& _Val)
+ { // replace each satisfying _Pred with _Val
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Pred);
+ for (; _First != _Last; ++_First)
+ if (_Pred(*_First))
+ *_First = _Val;
+ }
+
+template<class _FwdIt,
+ class _Pr,
+ class _Ty> inline
+ void replace_if(_FwdIt _First, _FwdIt _Last, _Pr _Pred, const _Ty& _Val)
+ { // replace each satisfying _Pred with _Val
+ _Replace_if(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Pred, _Val);
+ }
+
+ // TEMPLATE FUNCTION replace_copy
+template<class _InIt, class _OutIt, class _Ty, class _InOutItCat>
+inline
+ _OutIt _Replace_copy(_InIt _First, _InIt _Last, _OutIt _Dest,
+ const _Ty& _Oldval, const _Ty& _Newval,
+ _InOutItCat, _Range_checked_iterator_tag)
+ { // copy replacing each matching _Oldval with _Newval
+ _DEBUG_RANGE(_First, _Last);
+ _DEBUG_POINTER(_Dest);
+ for (; _First != _Last; ++_First, ++_Dest)
+ *_Dest = *_First == _Oldval ? _Newval : *_First;
+ return (_Dest);
+ }
+
+#if _SECURE_SCL
+template<class _InIt, class _OutIt, class _Ty>
+inline
+ _OutIt _Replace_copy(_InIt _First, _InIt _Last, _OutIt _Dest,
+ const _Ty& _Oldval, const _Ty& _Newval,
+ random_access_iterator_tag, _Range_checked_iterator_tag)
+ { // copy replacing each matching _Oldval with _Newval
+ // for range checked iterators, this will make sure there is enough space
+ _OutIt _Result = _Dest + (_Last - _First);
+ _Replace_copy(_First, _Last, _CHECKED_BASE(_Dest),
+ _Oldval, _Newval,
+ forward_iterator_tag(), _Range_checked_iterator_tag());
+ return (_Result);
+ }
+#endif
+
+#if _SECURE_SCL
+
+template<class _InIt,
+ class _OutIt,
+ class _Ty> inline
+_IF_CHK(_OutIt) replace_copy(_InIt _First, _InIt _Last, _OutIt _Dest,
+ const _Ty& _Oldval, const _Ty& _Newval)
+ { // copy replacing each matching _Oldval with _Newval
+ return _Replace_copy(_CHECKED_BASE(_First), _CHECKED_BASE(_Last), _Dest, _Oldval, _Newval,
+ _Iter_r...
[truncated message content] |