]> granicus.if.org Git - nethack/commitdiff
update lex output
authornethack.rankin <nethack.rankin>
Sun, 13 Jan 2002 04:16:04 +0000 (04:16 +0000)
committernethack.rankin <nethack.rankin>
Sun, 13 Jan 2002 04:16:04 +0000 (04:16 +0000)
sys/share/dgn_lex.c
sys/share/lev_lex.c

index 19c81118c01fe257307d3ca622d05089d585cd68..897ca17db97d5eaecf343e891a344c8f98ea5720 100644 (file)
@@ -481,33 +481,6 @@ void FDECL(init_yyout, (FILE *));
 extern YYSTYPE yylval;
 
 int line_number = 1;
-/*
- *     This is a hack required by Michael Hamel to get things
- *     working on the Mac.
- */
-#if defined(applec) && !defined(FLEX_SCANNER) && !defined(FLEXHACK_SCANNER)
-#undef input
-#undef unput
-#define unput(c) { yytchar = (c); if (yytchar == 10) yylineno--; *yysptr++ = yytchar; }                                
-# ifndef YYNEWLINE
-# define YYNEWLINE 10
-# endif
-
-char
-input()                /* Under MPW \n is chr(13)! Compensate for this. */
-{
-       if (yysptr > yysbuf) return(*--yysptr);
-       else {
-               yytchar = getc(yyin);
-               if (yytchar == '\n') {
-                   yylineno++;
-                   return(YYNEWLINE);
-               }
-               if (yytchar == EOF) return(0);
-               else                return(yytchar);
-       }
-}
-#endif /* applec && !FLEX_SCANNER && !FLEXHACK_SCANNER */
 
 
 /* Macros after this point can all be overridden by user definitions in
index b2d15b0291267f2877da6297905cbb1cb0fd23c0..24da7a264025762f5b6cef70cdece09411e6c1e4 100644 (file)
@@ -750,34 +750,6 @@ int line_number = 1, colon_line_number = 1;
 static char map[4096];
 static int map_cnt = 0;
 
-/*
- *     This is a hack required by Michael Hamel to get things
- *     working on the Mac.
- */
-#if defined(applec) && !defined(FLEX_SCANNER) && !defined(FLEXHACK_SCANNER)
-#undef input
-#undef unput
-#define unput(c) { yytchar = (c); if (yytchar == 10) yylineno--; *yysptr++ = yytchar; }
-# ifndef YYNEWLINE
-# define YYNEWLINE 10
-# endif
-
-char
-input()                /* Under MPW \n is chr(13)! Compensate for this. */
-{
-       if (yysptr > yysbuf) return(*--yysptr);
-       else {
-               yytchar = getc(yyin);
-               if (yytchar == '\n') {
-                   yylineno++;
-                   return(YYNEWLINE);
-               }
-               if (yytchar == EOF) return(0);
-               else                return(yytchar);
-       }
-}
-#endif /* applec && !FLEX_SCANNER && !FLEXHACK_SCANNER */
-
 #define MAPC 1