Commit Graph

31 Commits

Author SHA1 Message Date
Johannes Schickel
c2fd35c9ed COMMON: Make value parameter of fill a const reference. 2011-11-16 18:16:40 +01:00
Johannes Schickel
61795739f8 COMMON: Rename Common::set_to to Common::fill.
This makes the name match with the name of the STL function with the same
behavior.
2011-11-16 18:06:30 +01:00
Christoph Mallon
84220d2ca0 COMMON: Remove superfluous Common:: qualifiers. 2011-08-07 15:19:07 +02:00
Christoph Mallon
23a0f5318c JANITORIAL: Remove trailing empty lines. 2011-08-07 13:53:33 +02:00
Johannes Schickel
263adb5cfc COMMON: Limit pragma warning use in algorithm.h to MSVC.
Since we only want to disable a MSVC specific warning with it and other
compilers might have different warnings numbers it is safer to only target
MSVC here.
2011-05-29 21:12:42 +02:00
Littleboy
89e954c653 COMMON: Silence MSVC warning for Common::gcd calls with an unsigned type 2011-05-24 00:56:48 -04:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Max Horn
2184326dbc COMMON: Add comment that explains strange <= checks in gcd()
svn-id: r55838
2011-02-09 00:11:39 +00:00
Johannes Schickel
4306a65577 COMMON: Revert attempt to silence MSVC warning in Common::gcd.
svn-id: r53506
2010-10-15 18:20:01 +00:00
Johannes Schickel
5c102d4f08 COMMON: Silence gcc warning introduced with r53496.
svn-id: r53497
2010-10-15 14:18:58 +00:00
Johannes Schickel
8fc3c21bd0 COMMON: Attempt to silence MSVC warning in Common::gcd.
svn-id: r53496
2010-10-15 14:14:51 +00:00
Johannes Schickel
f75d84cbdd JANITORIAL: Some small explanation about stability of sorting algorithms.
Special thanks to lskovlun for his suggestion to add this.

svn-id: r51524
2010-07-30 23:42:50 +00:00
Johannes Schickel
8e8023d7cc JANITORIAL: Add comment about the stability of Common::sort.
svn-id: r51522
2010-07-30 23:24:22 +00:00
Max Horn
00cd966f3d Some tweaks and fixes for Common::Rational
* Fix Common::gcd to work with negative input
* This fixes a bug in Common::Rational's multiplication code
* Add some more basic unit tests (including one which checks for
  the now fixed multiplication bug)
* cleanup

svn-id: r49064
2010-05-17 22:07:58 +00:00
Matthew Hoops
811fc0e7ec Add the Common::Rational class from patch #2963496 (VideoDecoder Rewrite)
svn-id: r49061
2010-05-17 20:53:04 +00:00
Johannes Schickel
a0f90fd603 Add common/util.h include to common/algorithm.h for SWAP.
This should fix the compilation with clang++, see bug report
 #2971226 "COMMON: Compile error - SWAP undeclared in algorithm.h".

svn-id: r48307
2010-03-20 12:13:37 +00:00
Max Horn
ebbc33c3ca Spelling: Par*r*tition
svn-id: r46688
2009-12-28 21:04:35 +00:00
Vladimir Menshakov
3936861b7c allowed list to be sorted with default comparator
svn-id: r46644
2009-12-27 14:13:39 +00:00
Johannes Schickel
69ba1ee04d Some more code format fixes.
svn-id: r46641
2009-12-27 13:58:00 +00:00
Vladimir Menshakov
cddb95d9c3 more code convention fixes
svn-id: r46640
2009-12-27 13:33:12 +00:00
Vladimir Menshakov
17380ba06e added whitespace to conform code convention
svn-id: r46639
2009-12-27 13:25:07 +00:00
Vladimir Menshakov
668ecc5d38 replaced bubble sort with quick sort
added distance(a, b) functions

svn-id: r46638
2009-12-27 13:19:44 +00:00
Max Horn
f242266f6d Change a couple places from 'end of namespace' to 'End of namespace', for consistency
svn-id: r44634
2009-10-04 21:26:33 +00:00
Jordi Vilalta Prat
b1999a2a16 Fixed indentation and removed whitespaces at the end of line
svn-id: r35481
2008-12-22 11:22:15 +00:00
Johannes Schickel
0a95a4814c Added documentation for the functions in algorithm.h.
svn-id: r33416
2008-07-29 17:00:15 +00:00
Johannes Schickel
d8e1f5a060 - make Common::sort supporting a function object to compare two entries instead of operator <
- adapt parallaction to use the new Common::sort function

svn-id: r30692
2008-01-28 22:05:23 +00:00
Max Horn
becce923fc BE -> AE
svn-id: r30376
2008-01-10 12:22:15 +00:00
Johannes Schickel
cec8b98201 Added 'specialized' versions of set_to for char*, signed char* and unsigned char* 'In' parameters.
svn-id: r29523
2007-11-17 00:19:27 +00:00
Johannes Schickel
89edc3c7eb Adds Common::set_to which sets elements from the range [first, last) to value.
svn-id: r29080
2007-09-24 00:07:28 +00:00
Max Horn
218e132e37 Updated legal headers in source files, based on what Pidgin (the IM client formerly knowns as Gaim) does; added new (incomplete) COPYRIGHT file; updated copyright dates in a few spots
svn-id: r27024
2007-05-30 21:56:52 +00:00
Johannes Schickel
ad03c72bdb Commit of patch #1715313 ("CORE: STL like algorithm implementation").
svn-id: r26929
2007-05-23 12:02:31 +00:00