[Scummvm-cvs-logs] SF.net SVN: scummvm: [21618] scummvm/trunk/common/func.h
fingolfin at users.sourceforge.net
fingolfin at users.sourceforge.net
Tue Apr 4 16:59:01 CEST 2006
Revision: 21618
Author: fingolfin
Date: 2006-04-04 16:57:56 -0700 (Tue, 04 Apr 2006)
ViewCVS: http://svn.sourceforge.net/scummvm/?rev=21618&view=rev
Log Message:
-----------
Re-fix sort by renaming min to minElem (avoid conflicts with certain system headers that #define min)
Modified Paths:
--------------
scummvm/trunk/common/func.h
Modified: scummvm/trunk/common/func.h
===================================================================
--- scummvm/trunk/common/func.h 2006-04-04 23:55:47 UTC (rev 21617)
+++ scummvm/trunk/common/func.h 2006-04-04 23:57:56 UTC (rev 21618)
@@ -73,14 +73,14 @@
// Simple selection sort
T i(first);
for (; i != last; ++i) {
- T min(i);
+ T minElem(i);
T j(i);
++j;
for (; j != last; ++j)
- if (*j < *min)
- min = j;
- if (min != i)
- SWAP(*min, *i);
+ if (*j < *minElem)
+ minElem = j;
+ if (minElem != i)
+ SWAP(*minElem, *i);
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list