@@ -231,15 +231,15 @@ get_type(enum ECPGttype type)
231
231
*/
232
232
static void ECPGdump_a_simple (FILE * o , const char * name , enum ECPGttype type ,
233
233
char * varcharsize ,
234
- char * arrsiz , const char * siz , const char * prefix , int );
235
- static void ECPGdump_a_struct (FILE * o , const char * name , const char * ind_name , char * arrsiz ,
234
+ char * arrsize , const char * size , const char * prefix , int );
235
+ static void ECPGdump_a_struct (FILE * o , const char * name , const char * ind_name , char * arrsize ,
236
236
struct ECPGtype * type , struct ECPGtype * ind_type , const char * prefix , const char * ind_prefix );
237
237
238
238
void
239
239
ECPGdump_a_type (FILE * o , const char * name , struct ECPGtype * type , const int brace_level ,
240
240
const char * ind_name , struct ECPGtype * ind_type , const int ind_brace_level ,
241
241
const char * prefix , const char * ind_prefix ,
242
- char * arr_str_siz , const char * struct_sizeof ,
242
+ char * arr_str_size , const char * struct_sizeof ,
243
243
const char * ind_struct_sizeof )
244
244
{
245
245
struct variable * var ;
@@ -350,9 +350,9 @@ ECPGdump_a_type(FILE *o, const char *name, struct ECPGtype * type, const int bra
350
350
if (indicator_set && (ind_type -> type == ECPGt_struct || ind_type -> type == ECPGt_array ))
351
351
mmfatal (INDICATOR_NOT_SIMPLE , "indicator for simple data type has to be simple" );
352
352
353
- ECPGdump_a_simple (o , name , type -> type , str_varchar_one , (arr_str_siz && strcmp (arr_str_siz , "0" ) != 0 ) ? arr_str_siz : str_arr_one , struct_sizeof , prefix , 0 );
353
+ ECPGdump_a_simple (o , name , type -> type , str_varchar_one , (arr_str_size && strcmp (arr_str_size , "0" ) != 0 ) ? arr_str_size : str_arr_one , struct_sizeof , prefix , 0 );
354
354
if (ind_type != NULL )
355
- ECPGdump_a_simple (o , ind_name , ind_type -> type , ind_type -> size , (arr_str_siz && strcmp (arr_str_siz , "0" ) != 0 ) ? arr_str_siz : str_neg_one , ind_struct_sizeof , ind_prefix , 0 );
355
+ ECPGdump_a_simple (o , ind_name , ind_type -> type , ind_type -> size , (arr_str_size && strcmp (arr_str_size , "0" ) != 0 ) ? arr_str_size : str_neg_one , ind_struct_sizeof , ind_prefix , 0 );
356
356
357
357
free (str_varchar_one );
358
358
free (str_arr_one );
@@ -391,9 +391,9 @@ ECPGdump_a_type(FILE *o, const char *name, struct ECPGtype * type, const int bra
391
391
if (indicator_set && (ind_type -> type == ECPGt_struct || ind_type -> type == ECPGt_array ))
392
392
mmfatal (INDICATOR_NOT_SIMPLE , "indicator for simple data type has to be simple" );
393
393
394
- ECPGdump_a_simple (o , name , type -> type , type -> size , (arr_str_siz && strcmp (arr_str_siz , "0" ) != 0 ) ? arr_str_siz : str_neg_one , struct_sizeof , prefix , type -> counter );
394
+ ECPGdump_a_simple (o , name , type -> type , type -> size , (arr_str_size && strcmp (arr_str_size , "0" ) != 0 ) ? arr_str_size : str_neg_one , struct_sizeof , prefix , type -> counter );
395
395
if (ind_type != NULL )
396
- ECPGdump_a_simple (o , ind_name , ind_type -> type , ind_type -> size , (arr_str_siz && strcmp (arr_str_siz , "0" ) != 0 ) ? arr_str_siz : ind_type_neg_one , ind_struct_sizeof , ind_prefix , 0 );
396
+ ECPGdump_a_simple (o , ind_name , ind_type -> type , ind_type -> size , (arr_str_size && strcmp (arr_str_size , "0" ) != 0 ) ? arr_str_size : ind_type_neg_one , ind_struct_sizeof , ind_prefix , 0 );
397
397
398
398
free (str_neg_one );
399
399
free (ind_type_neg_one );
@@ -403,13 +403,13 @@ ECPGdump_a_type(FILE *o, const char *name, struct ECPGtype * type, const int bra
403
403
}
404
404
405
405
406
- /* If siz is NULL, then the offset is 0, if not use siz as a
406
+ /* If size is NULL, then the offset is 0, if not use size as a
407
407
string, it represents the offset needed if we are in an array of structs. */
408
408
static void
409
409
ECPGdump_a_simple (FILE * o , const char * name , enum ECPGttype type ,
410
410
char * varcharsize ,
411
411
char * arrsize ,
412
- const char * siz ,
412
+ const char * size ,
413
413
const char * prefix ,
414
414
int counter )
415
415
{
@@ -440,7 +440,7 @@ ECPGdump_a_simple(FILE *o, const char *name, enum ECPGttype type,
440
440
*/
441
441
if (((atoi (arrsize ) > 0 ) ||
442
442
(atoi (arrsize ) == 0 && strcmp (arrsize , "0" ) != 0 )) &&
443
- siz == NULL )
443
+ size == NULL )
444
444
sprintf (variable , "(%s%s)" , prefix ? prefix : "" , name );
445
445
else
446
446
sprintf (variable , "&(%s%s)" , prefix ? prefix : "" , name );
@@ -469,7 +469,7 @@ ECPGdump_a_simple(FILE *o, const char *name, enum ECPGttype type,
469
469
(atoi (arrsize ) > 0 ) ||
470
470
(atoi (varcharsize ) == 0 && strcmp (varcharsize , "0" ) != 0 ) ||
471
471
(atoi (arrsize ) == 0 && strcmp (arrsize , "0" ) != 0 ))
472
- && siz == NULL )
472
+ && size == NULL )
473
473
{
474
474
sprintf (variable , "(%s%s)" , prefix ? prefix : "" , name );
475
475
if ((type == ECPGt_char || type == ECPGt_unsigned_char ) &&
@@ -536,7 +536,7 @@ ECPGdump_a_simple(FILE *o, const char *name, enum ECPGttype type,
536
536
*/
537
537
if (((atoi (arrsize ) > 0 ) ||
538
538
(atoi (arrsize ) == 0 && strcmp (arrsize , "0" ) != 0 )) &&
539
- siz == NULL )
539
+ size == NULL )
540
540
sprintf (variable , "(%s%s)" , prefix ? prefix : "" , name );
541
541
else
542
542
sprintf (variable , "&(%s%s)" , prefix ? prefix : "" , name );
@@ -549,17 +549,17 @@ ECPGdump_a_simple(FILE *o, const char *name, enum ECPGttype type,
549
549
* Array size would be -1 for addresses of members within structure,
550
550
* when pointer to structure is being dumped.
551
551
*/
552
- if (atoi (arrsize ) < 0 && !siz )
552
+ if (atoi (arrsize ) < 0 && !size )
553
553
strcpy (arrsize , "1" );
554
554
555
555
/*
556
- * If siz i.e. the size of structure of which this variable is part
556
+ * If size i.e. the size of structure of which this variable is part
557
557
* of, that gives the offset to the next element, if required
558
558
*/
559
- if (siz == NULL || strlen (siz ) == 0 )
559
+ if (size == NULL || strlen (size ) == 0 )
560
560
fprintf (o , "\n\t%s,%s,(long)%s,(long)%s,%s, " , get_type (type ), variable , varcharsize , arrsize , offset );
561
561
else
562
- fprintf (o , "\n\t%s,%s,(long)%s,(long)%s,%s, " , get_type (type ), variable , varcharsize , arrsize , siz );
562
+ fprintf (o , "\n\t%s,%s,(long)%s,(long)%s,%s, " , get_type (type ), variable , varcharsize , arrsize , size );
563
563
564
564
free (variable );
565
565
free (offset );
@@ -569,7 +569,7 @@ ECPGdump_a_simple(FILE *o, const char *name, enum ECPGttype type,
569
569
570
570
/* Penetrate a struct and dump the contents. */
571
571
static void
572
- ECPGdump_a_struct (FILE * o , const char * name , const char * ind_name , char * arrsiz , struct ECPGtype * type , struct ECPGtype * ind_type , const char * prefix , const char * ind_prefix )
572
+ ECPGdump_a_struct (FILE * o , const char * name , const char * ind_name , char * arrsize , struct ECPGtype * type , struct ECPGtype * ind_type , const char * prefix , const char * ind_prefix )
573
573
{
574
574
/*
575
575
* If offset is NULL, then this is the first recursive level. If not then
@@ -580,7 +580,7 @@ ECPGdump_a_struct(FILE *o, const char *name, const char *ind_name, char *arrsiz,
580
580
char * pbuf = (char * ) mm_alloc (strlen (name ) + ((prefix == NULL ) ? 0 : strlen (prefix )) + 3 );
581
581
char * ind_pbuf = (char * ) mm_alloc (strlen (ind_name ) + ((ind_prefix == NULL ) ? 0 : strlen (ind_prefix )) + 3 );
582
582
583
- if (atoi (arrsiz ) == 1 )
583
+ if (atoi (arrsize ) == 1 )
584
584
sprintf (pbuf , "%s%s." , prefix ? prefix : "" , name );
585
585
else
586
586
sprintf (pbuf , "%s%s->" , prefix ? prefix : "" , name );
@@ -591,7 +591,7 @@ ECPGdump_a_struct(FILE *o, const char *name, const char *ind_name, char *arrsiz,
591
591
ind_p = & struct_no_indicator ;
592
592
else if (ind_type != NULL )
593
593
{
594
- if (atoi (arrsiz ) == 1 )
594
+ if (atoi (arrsize ) == 1 )
595
595
sprintf (ind_pbuf , "%s%s." , ind_prefix ? ind_prefix : "" , ind_name );
596
596
else
597
597
sprintf (ind_pbuf , "%s%s->" , ind_prefix ? ind_prefix : "" , ind_name );
@@ -606,7 +606,7 @@ ECPGdump_a_struct(FILE *o, const char *name, const char *ind_name, char *arrsiz,
606
606
(ind_p != NULL ) ? ind_p -> name : NULL ,
607
607
(ind_p != NULL ) ? ind_p -> type : NULL ,
608
608
-1 ,
609
- prefix , ind_prefix , arrsiz , type -> struct_sizeof ,
609
+ prefix , ind_prefix , arrsize , type -> struct_sizeof ,
610
610
(ind_p != NULL ) ? ind_type -> struct_sizeof : NULL );
611
611
if (ind_p != NULL && ind_p != & struct_no_indicator )
612
612
ind_p = ind_p -> next ;
0 commit comments