This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Patch] libstdc++/29989


Hi,

this PR is really a duplicate of 23273, but in my opinion calls for the below patchlet: std::max and std::min are not special and we are not supposed to undef anything before introducing the definitions. In fact, the presence of the undefs may mislead the users to believe that before other std names (all of them?!?) undefs are also needed, as happened in the PR at issue.

Tested x86-linux, will wait until tomorrow.

Paolo.

//////////////////////
2006-12-03  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/29989
	* include/bits/stl_algobase.h: Remove min and max #undefs.
Index: include/bits/stl_algobase.h
===================================================================
--- include/bits/stl_algobase.h	(revision 119449)
+++ include/bits/stl_algobase.h	(working copy)
@@ -167,9 +167,6 @@
 	iter_swap(__a, __b);
     }
 
-#undef min
-#undef max
-
   /**
    *  @brief This does what you think it does.
    *  @param  a  A thing of arbitrary type.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]