diff options
author | Maho Nakata <maho@FreeBSD.org> | 2005-04-08 01:27:27 +0000 |
---|---|---|
committer | Maho Nakata <maho@FreeBSD.org> | 2005-04-08 01:27:27 +0000 |
commit | ea5e91b3f99449607924a61be5b5addb11d0c6ee (patch) | |
tree | 3cc40fc7d98904a314d4c58e8591a14b5f69d12c /editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx | |
parent | \*kde\* matches too many ports, kde\* \*kde-i18n\* should be safer. (diff) |
Update to m91
Notes
Notes:
svn path=/head/; revision=132732
Diffstat (limited to 'editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx')
-rw-r--r-- | editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx b/editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx new file mode 100644 index 000000000000..5c0c6bd78884 --- /dev/null +++ b/editors/openoffice.org-3-devel/files/patch-canvas+inc+canvas+canvastools.hxx @@ -0,0 +1,21 @@ + +Index: canvas/inc/canvas/canvastools.hxx +=================================================================== +RCS file: /cvs/gsl/canvas/inc/canvas/canvastools.hxx,v +retrieving revision 1.7 +diff -u -r1.7 canvastools.hxx +--- canvas/inc/canvas/canvastools.hxx 30 Mar 2005 07:34:18 -0000 1.7 ++++ canvas/inc/canvas/canvastools.hxx 6 Apr 2005 01:22:58 -0000 +@@ -133,9 +133,9 @@ + */ + + // mickey's math tricks... +- inline unsigned int powerof2( unsigned int c ) { return 0x1 << c; } +- inline unsigned int mask( unsigned int c ) { return ((unsigned int)(-1)) / (powerof2(powerof2(c)) + 1); } +- inline unsigned int count( unsigned int x, unsigned int c ) { return ((x) & mask(c)) + (((x) >> (powerof2(c))) & mask(c)); } ++ inline unsigned int powerof2_ooo( unsigned int c ) { return 0x1 << c; } ++ inline unsigned int mask( unsigned int c ) { return ((unsigned int)(-1)) / (powerof2_ooo(powerof2_ooo(c)) + 1); } ++ inline unsigned int count( unsigned int x, unsigned int c ) { return ((x) & mask(c)) + (((x) >> (powerof2_ooo(c))) & mask(c)); } + template<typename T> + inline unsigned int bitcount( T c ) { + unsigned int nByteIndex = 0; |