git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@3587
4a8a32a2-be11-0410-ad9d-
d568d2c75423
2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
- * device/lib/printf_large.c (_print_format): fixed bug 1073386,
- (calculate_digit): added optimization for octal and hex
+ * device/lib/printf_large.c (_print_format): fixed bug 1073386
* support/regression/tests/bug1057979.c: added test for bug 1073386
2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
* support/regression/tests/bug1057979.c: added test for bug 1073386
2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
#if defined ASM_ALLOWED
static void calculate_digit( unsigned char radix )
{
#if defined ASM_ALLOWED
static void calculate_digit( unsigned char radix )
{
- if (radix == 8)
- {
- value.byte[4] = value.ul & 0x07;
- value.ul >>= 3;
- }
- else if (radix == 16)
- {
- value.byte[4] = value.ul & 0x0F;
- value.ul >>= 4;
- }
- else
- {
unsigned char i;
for( i = 32; i != 0; i-- )
unsigned char i;
for( i = 32; i != 0; i-- )
#elif defined SDCC_STACK_AUTO
static void calculate_digit( value_t* value, unsigned char radix )
{
#elif defined SDCC_STACK_AUTO
static void calculate_digit( value_t* value, unsigned char radix )
{
- if (radix == 8)
- {
- value->byte[4] = value->ul & 0x07;
- value->ul >>= 3;
- }
- else if (radix == 16)
- {
- value->byte[4] = value->ul & 0x0F;
- value->ul >>= 4;
- }
- else
- {
unsigned char i;
for( i = 32; i != 0; i-- )
unsigned char i;
for( i = 32; i != 0; i-- )
#else
static void calculate_digit( unsigned char radix )
{
#else
static void calculate_digit( unsigned char radix )
{
- if (radix == 8)
- {
- value.byte[4] = value.ul & 0x07;
- value.ul >>= 3;
- }
- else if (radix == 16)
- {
- value.byte[4] = value.ul & 0x0F;
- value.ul >>= 4;
- }
- else
- {
unsigned char i;
for( i = 32; i != 0; i-- )
unsigned char i;
for( i = 32; i != 0; i-- )
value.l = va_arg(ap,char);
if (!signed_argument)
{
value.l = va_arg(ap,char);
if (!signed_argument)
{
}
}
else if (long_argument)
}
}
else if (long_argument)