Re: [Flex-devel] Own declaration of isatty() necessary?
flex is a tool for generating scanners
Brought to you by:
wlestes
From: Will E. <wes...@gm...> - 2012-02-17 21:48:26
|
This has been fixed in the flex cvs tree, and the relevant sourceforge bug items closed. On Wednesday, 8 February 2012, 8:53 pm +0000, Tim Landscheidt <ti...@ti...> wrote: > Hi Will, > > > Autoconf could test for isatty's declaration/presence and we could > > conditionally define it if need be. > > > I'm not convinced that it's still an issue, though, so my preference is > > just to remove the isatty declaration. > > [...] > > But the scanner can get generated on one machine and compil- > ed on another. flex is the prime example for this: scan.c > is generated at release on the maintainer's box and compiled > on every supported platform. Other projects might not even > use autoconf. > > Anyway, attached is a patch to remove this. > > Tim > > P. S.: Please keep discussions public if possible so that > others can chip in. > From 534ff13e77ea60b3b83b155d20ac6b5f18c9a821 Mon Sep 17 00:00:00 2001 > From: Tim Landscheidt <ti...@ti...> > Date: Wed, 8 Feb 2012 20:39:08 +0000 > Subject: [PATCH] Remove own declaration of isatty(). > > This fixes bugs #1984987 and #2705528. > --- > flex.skl | 19 ------------------- > 1 files changed, 0 insertions(+), 19 deletions(-) > > diff --git a/flex.skl b/flex.skl > index 60c141f..6285def 100644 > --- a/flex.skl > +++ b/flex.skl > @@ -2055,25 +2055,6 @@ static void yy_load_buffer_state YYFARGS0(void) > } > > > -%if-c-only > -m4_ifdef( [[M4_YY_ALWAYS_INTERACTIVE]],, > -[[ > - m4_ifdef( [[M4_YY_NEVER_INTERACTIVE]],, > - [[ > -#ifndef __cplusplus > -extern int isatty M4_YY_PARAMS( int ); > -#endif /* __cplusplus */ > - ]]) > -]]) > -%endif > - > -%if-c++-only > -m4_ifdef( [[M4_YY_NEVER_INTERACTIVE]],, > -[[ > -extern "C" int isatty M4_YY_PARAMS( int ); > -]]) > -%endif > - > /* Initializes or reinitializes a buffer. > * This function is sometimes called more than once on the same buffer, > * such as during a yyrestart() or at EOF. > -- > 1.6.2.5 > |