[warning-fix][bad-format-type]

This commit is contained in:
tpaviot
2011-07-31 23:31:09 +02:00
parent 922a7957c4
commit e52c2907cf
4 changed files with 17 additions and 17 deletions
+1 -1
View File
@@ -50,7 +50,7 @@ DICTprint(Dictionary dict)
HASHlistinit(dict,&de);
while (0 != (e = (HASHlist(&de)))) {
printf("key <%s> data <%x> line <%d> <\"%c\" %s> <%s>\n",
printf("key <%s> data <%s> line <%d> <\"%c\" %s> <%s>\n",
e->key,e->data,e->symbol->line,e->type,
OBJget_type(e->type),e->symbol->filename);
}
+1 -1
View File
@@ -214,7 +214,7 @@ VARget_simple_name(Variable v)
e = e->e.op2;
break;
default:
fprintf(stderr,"unexpected op_code (%s) encountered in variable name expression\n",opcode_print(e->e.op_code));
fprintf(stderr,"unexpected op_code (%d) encountered in variable name expression\n",opcode_print(e->e.op_code));
abort();
}
}
+8 -8
View File
@@ -2421,7 +2421,7 @@ MemberFunctionSign (Entity entity, FILE* file)
/* //////////////// */
if(corba_binding)
{
fprintf(file, "\n//\t%s_ptr create_TIE();\n\tIDL_Application_instance_ptr create_TIE();\n",
fprintf(file, "\n//\t%d_ptr create_TIE();\n\tIDL_Application_instance_ptr create_TIE();\n",
ENTITYget_CORBAname(entity));
/*
fprintf(file, "\n//\t%s_ptr create_TIE();\n\tP26::Application_instance_ptr create_TIE();\n",
@@ -2438,7 +2438,7 @@ MemberFunctionSign (Entity entity, FILE* file)
fprintf (file, "};\n");
if(corba_binding)
{
fprintf (file, "\n// Associate IDL interface generated code with implementation object\nDEF_TIE_%s(%s)\n", ENTITYget_CORBAname(entity), entnm);
fprintf (file, "\n// Associate IDL interface generated code with implementation object\nDEF_TIE_%d(%s)\n", ENTITYget_CORBAname(entity), entnm);
}
/* Print ObjectStore Access Hook function */
@@ -3013,7 +3013,7 @@ LIBstructor_print (Entity entity, FILE* file, Schema schema)
{
fprintf (file,
"\n//%s_ptr \nIDL_Application_instance_ptr \n%s::create_TIE()\n{\n",
"\n//%d_ptr \nIDL_Application_instance_ptr \n%s::create_TIE()\n{\n",
ENTITYget_CORBAname(entity), entnm);
/*
fprintf (file,
@@ -3026,7 +3026,7 @@ LIBstructor_print (Entity entity, FILE* file, Schema schema)
" std::cout << \"Server creating entity: \" << markerName ");
fprintf (file,
"<< \" TIE object.\" << std::endl;\n");
fprintf (file, " return new TIE_%s(%s) (this, markerName);\n",
fprintf (file, " return new TIE_%d(%s) (this, markerName);\n",
ENTITYget_CORBAname(entity), entnm);
fprintf (file, "}\n");
@@ -3381,7 +3381,7 @@ print_typechain(FILE *f,const Type t,char *buf,Schema schema)
case set_:
case list_:
/* create a new TypeDescriptor variable, e.g. t1, and new space for it */
fprintf(f,"\t%s * %s%d = new %s;\n",
fprintf(f,"\t%d * %s%d = new %d;\n",
GetTypeDescriptorName(t), TD_PREFIX, count,
GetTypeDescriptorName(t) );
@@ -4644,7 +4644,7 @@ TYPEprint_typedefs (Type t, FILE *classes)
externln:
/* Print the extern statement: */
strncpy (nm, TYPEtd_name(t), BUFSIZ);
fprintf( classes, "extern %s \t*%s;\n", GetTypeDescriptorName(t), nm );
fprintf( classes, "extern %d \t*%s;\n", GetTypeDescriptorName(t), nm );
}
/* return 1 if it is a multidimensional aggregate at the level passed in
@@ -4814,7 +4814,7 @@ TYPEprint_descriptions (const Type type, FILES* files, Schema schema)
/* in source - declare the real definition of the pointer */
/* i.e. in the .cc file */
fprintf(files -> lib,"%s \t*%s;\n", GetTypeDescriptorName(type), tdnm);
fprintf(files -> lib,"%d \t*%s;\n", GetTypeDescriptorName(type), tdnm);
if(isAggregateType(type)) {
const char * ctype = TYPEget_ctype (type);
@@ -5218,7 +5218,7 @@ TYPEprint_new (const Type type, FILE *create, Schema schema)
case set_:
case list_:
fprintf(create,"\n\t%s = new %s (\n",
fprintf(create,"\n\t%s = new %d (\n",
TYPEtd_name (type), GetTypeDescriptorName(type));
/* fill in it's values */
+7 -7
View File
@@ -562,7 +562,7 @@ TYPEselect_inc_print_vars( const Type type, FILE *f, Linked_List dups)
fprintf( f, "/* \tunion { */\n" );
fprintf( f, "\t// types in SELECT \n" );
LISTdo( SEL_TYPEget_items(type), t, Type )
fprintf( f, "\t// %s\t-- %s\n",
fprintf( f, "\t// %s\t-- %d\n",
SEL_ITEMget_enumtype (t), FundamentalType (t));
LISTod;
@@ -1508,7 +1508,7 @@ TYPEselect_lib_part21 (const Type type, FILE* f, Schema schema)
fprintf(f, " return _%s.ValueType();\n else ", dm);
break;
default:
fprintf(f, " return %s;\n else ", FundamentalType(t,0));
fprintf(f, " return %d;\n else ", FundamentalType(t,0));
}
LISTod;
@@ -1736,19 +1736,19 @@ TYPEselect_lib_StrToVal (const Type type, FILE* f, Schema schema)
case enumeration_:
if (!enum_cnt) {
/* if there\'s more than one enumeration they are done in Select class */
fprintf (f, " case %s : \n", FundamentalType (t, 0));
fprintf (f, " case %d : \n", FundamentalType (t, 0));
fprintf( f,
"\treturn _%s.StrToVal (str, &_error);\n",
SEL_ITEMget_dmname (t));
}
else {
fprintf (f, " // case %s : done in Select class\n", FundamentalType (t, 0));
fprintf (f, " // case %d : done in Select class\n", FundamentalType (t, 0));
}
++enum_cnt;
break;
case string_:
fprintf (f, " case %s : \n", FundamentalType (t, 0));
fprintf (f, " case %d : \n", FundamentalType (t, 0));
fprintf( f,
"\treturn _%s.StrToVal (str);\n",
SEL_ITEMget_dmname (t));
@@ -1759,7 +1759,7 @@ TYPEselect_lib_StrToVal (const Type type, FILE* f, Schema schema)
case bag_:
case set_:
case list_:
fprintf (f, " case %s : \n", FundamentalType (t, 0));
fprintf (f, " case %d : \n", FundamentalType (t, 0));
fprintf( f,
"\treturn _%s.StrToVal (str, &_error, "
"%s -> AggrElemTypeDescriptor ());\n",
@@ -1770,7 +1770,7 @@ TYPEselect_lib_StrToVal (const Type type, FILE* f, Schema schema)
default:
/* otherwise use StrToVal on the contents to check the format */
fprintf (f, " case %s : \n", FundamentalType (t, 0));
fprintf (f, " case %d : \n", FundamentalType (t, 0));
fprintf( f,
"\treturn _%s -> StrToVal (str, instances);\n",
SEL_ITEMget_dmname (t));