aboutsummaryrefslogtreecommitdiff
path: root/gcc/genhooks.c
diff options
context:
space:
mode:
authorNathan Froyd <froydnj@codesourcery.com>2010-06-29 20:54:53 +0000
committerNathan Froyd <froydnj@gcc.gnu.org>2010-06-29 20:54:53 +0000
commit4d64faec41ba5da430b37ddfdf6bfdafa5cf6d83 (patch)
treead530cec98b875fbe153ab933253170695696120 /gcc/genhooks.c
parent087fa34bad4ee46be9cd53314161239ad75b0743 (diff)
downloadgcc-4d64faec41ba5da430b37ddfdf6bfdafa5cf6d83.zip
gcc-4d64faec41ba5da430b37ddfdf6bfdafa5cf6d83.tar.gz
gcc-4d64faec41ba5da430b37ddfdf6bfdafa5cf6d83.tar.bz2
genhooks.c (emit_findices): Cast field precision to int.
* genhooks.c (emit_findices): Cast field precision to int. (emit_documentation): Likewise. From-SVN: r161568
Diffstat (limited to 'gcc/genhooks.c')
-rw-r--r--gcc/genhooks.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/genhooks.c b/gcc/genhooks.c
index 66d3633..a9eecd7 100644
--- a/gcc/genhooks.c
+++ b/gcc/genhooks.c
@@ -52,7 +52,7 @@ emit_findices (const char *doc, const char *hook_name)
doc = strchr (fcode, '}');
if (!doc)
fatal ("Malformed @Fcode for hook %s\n", hook_name);
- printf ("@findex %.*s\n", doc - fcode, fcode);
+ printf ("@findex %.*s\n", (int) (doc - fcode), fcode);
doc = fcode;
}
}
@@ -238,9 +238,9 @@ emit_documentation (const char *in_fname)
/* Type names like 'int' are followed by a space, sometimes
also by '*'. 'void' should appear only in "(void)". */
if (*e == ' ' || *e == '*' || *q == '(')
- printf ("%.*s", e - q + 1, q);
+ printf ("%.*s", (int) (e - q + 1), q);
else
- printf ("@var{%.*s}%c", e - q, q, *e);
+ printf ("@var{%.*s}%c", (int) (e - q), q, *e);
}
/* POD-valued hooks sometimes come in groups with common
documentation.*/
@@ -265,8 +265,8 @@ emit_documentation (const char *in_fname)
/* Print paragraph, emitting @Fcode as @code. */
for (; (fcode = strstr (doc, "@Fcode{")) && fcode < p_end;
doc = fcode + 2)
- printf ("%.*s@", fcode - doc, doc);
- printf ("%.*s", p_end - doc, doc);
+ printf ("%.*s@", (int) (fcode - doc), doc);
+ printf ("%.*s", (int) (p_end - doc), doc);
/* Emit function indices for next paragraph. */
emit_findices (p_end, name);
}