+
+/* Lexical analysis of a file
+ Strips a filename to its base name, then sends it to lexer_lex
+*/
+int lexer_lexfile
+#define MAX_FNAME 2048
+#define HIDDEN_WARNING "%s is hidden and will not be parsed!\n", filename
+( const char *filename
+)
+{ static char fname[MAX_FNAME];
+ char *last_period = NULL, *iter;
+
+ if (*filename == '.')
+ { fprintf (stderr, HIDDEN_WARNING);
+ return 0;
+ }
+ strncpy(fname,filename,MAX_FNAME);
+ last_period = NULL;
+ for (iter = fname; *iter; iter++)
+ if (*iter == '.')
+ { if (iter == fname)
+ last_period = iter;
+ }
+ if (last_period)
+ *last_period = '\0';
+
+ return lexer_lex(fname);
+}