1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-09 01:28:58 +00:00

Some renaming

git-svn-id: svn://svn.cc65.org/cc65/trunk@3136 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz 2004-06-29 20:35:39 +00:00
parent daf8e0d1e6
commit e8afc897cf
2 changed files with 17 additions and 27 deletions

View File

@ -6,10 +6,10 @@
/* */
/* */
/* */
/* (C) 1998 Ullrich von Bassewitz */
/* Wacholderweg 14 */
/* D-70597 Stuttgart */
/* EMail: uz@musoftware.de */
/* (C) 1998-2004 Ullrich von Bassewitz */
/* Römerstraße 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
/* */
/* */
/* This software is provided 'as-is', without any expressed or implied */
@ -38,34 +38,24 @@
/*****************************************************************************/
/* data */
/* Code */
/*****************************************************************************/
/*****************************************************************************/
/* code */
/*****************************************************************************/
int powerof2 (unsigned long val)
int PowerOf2 (unsigned long Val)
/* Return the exponent if val is a power of two. Return -1 if val is not a
* power of two.
*/
{
int i;
unsigned long mask;
mask = 0x0001;
int I;
unsigned long Mask = 0x0001;
for (i = 0; i < 32; ++i) {
if (val == mask) {
return i;
for (I = 0; I < 32; ++I) {
if (Val == Mask) {
return I;
}
mask <<= 1;
Mask <<= 1;
}
return -1;
}

View File

@ -6,10 +6,10 @@
/* */
/* */
/* */
/* (C) 1998 Ullrich von Bassewitz */
/* Wacholderweg 14 */
/* D-70597 Stuttgart */
/* EMail: uz@musoftware.de */
/* (C) 1998-2004 Ullrich von Bassewitz */
/* Römerstraße 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
/* */
/* */
/* This software is provided 'as-is', without any expressed or implied */
@ -44,7 +44,7 @@
int powerof2 (unsigned long val);
int PowerOf2 (unsigned long Val);
/* Return the exponent if val is a power of two. Return -1 if val is not a
* power of two.
*/