#endif
int scan_file (char *filename);
-int scan_lisp_file (char *filename, char *mode);
-int scan_c_file (char *filename, char *mode);
-void fatal (char *s1, char *s2) NO_RETURN;
+int scan_lisp_file (const char *filename, const char *mode);
+int scan_c_file (char *filename, const char *mode);
+void fatal (const char *s1, const char *s2) NO_RETURN;
#ifdef MSDOS
/* s/msdos.h defines this as sys_chdir, but we're not linking with the
/* VARARGS1 */
void
-error (char *s1, char *s2)
+error (const char *s1, const char *s2)
{
fprintf (stderr, "%s: ", progname);
fprintf (stderr, s1, s2);
/* VARARGS1 */
void
-fatal (char *s1, char *s2)
+fatal (const char *s1, const char *s2)
{
error (s1, s2);
exit (EXIT_FAILURE);
int
scan_file (char *filename)
{
- int len = strlen (filename);
+
+ size_t len = strlen (filename);
put_filename (filename);
if (len > 4 && !strcmp (filename + len - 4, ".elc"))
/* A keyword we look for at the beginning of lines. If found, it is
not copied, and SAW_KEYWORD is set to true. */
- char *keyword;
+ const char *keyword;
/* The current point we've reached in an occurrence of KEYWORD in
the input stream. */
- char *cur_keyword_ptr;
+ const char *cur_keyword_ptr;
/* Set to true if we saw an occurrence of KEYWORD. */
int saw_keyword;
};
keyword, but it was a false alarm. Output the
part we scanned. */
{
- char *p;
+ const char *p;
for (p = state->keyword; p < state->cur_keyword_ptr; p++)
put_char (*p, state);
register char *p;
int in_ident = 0;
char *ident_start;
- int ident_length = 0;
+ size_t ident_length = 0;
fprintf (out, "(fn");
Accepts any word starting DEF... so it finds DEFSIMPLE and DEFPRED. */
int
-scan_c_file (char *filename, char *mode)
+scan_c_file (char *filename, const char *mode)
{
FILE *infile;
register int c;
}
int
-scan_lisp_file (char *filename, char *mode)
+scan_lisp_file (const char *filename, const char *mode)
{
FILE *infile;
register int c;