summaryrefslogtreecommitdiff
path: root/NEWS
blob: 4181bec5dcdd360287c4b80d5256586b71e6e50a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
Changes between 2.2 Patch #3 (30Mar90) and 2.2 Patch #2:

	- fixed bug which caused -I scanners to bomb


Changes between 2.2 Patch #2 (27Mar90) and 2.2 Patch #1:

	- fixed bug writing past end of input buffer in yyunput()
	- fixed bug detecting NUL's at the end of a buffer


Changes between 2.2 Patch #1 (23Mar90) and 2.2 (alpha) release:

	- Makefile fixes: definition of MAKE variable for systems
	  which don't have it; installation of flexdoc.1 along with
	  flex.1; fixed two bugs which could cause "bigtest" to fail.

	- flex.skel fix for compiling with g++.

	- README and flexdoc.1 no longer list an out-of-date BITNET address
	  for contacting me.

	- minor typos and formatting changes to flex.1 and flexdoc.1.


Changes between 2.2 (alpha) release of March '90 and previous release:

    User-visible:

	- Full user documentation now available.

	- Support for 8-bit scanners.

	- Scanners now accept NUL's.

	- A facility has been added for dealing with multiple
	  input buffers.

	- Two manual entries now.  One which fully describes flex
	  (rather than just its differences from lex), and the
	  other for quick(er) reference.

	- A number of changes to bring flex closer into compliance
	  with the latest POSIX lex draft:

		%t support
		flex now accepts multiple input files and concatenates
		    them together to form its input
		previous -c (compress) flag renamed -C
		do-nothing -c and -n flags added
		Any indented code or code within %{}'s in section 2 is
		    now copied to the output

	- yyleng is now a bona fide global integer.

	- -d debug information now gives the line number of the
	  matched rule instead of which number rule it was from
	  the beginning of the file.

	- -v output now includes a summary of the flags used to generate
	  the scanner.

	- unput() and yyrestart() are now globally callable.

	- yyrestart() no longer closes the previous value of yyin.

	- C++ support; generated scanners can be compiled with C++ compiler.

	- Primitive -lfl library added, containing default main()
	  which calls yylex().  A number of routines currently living
	  in the scanner skeleton will probably migrate to here
	  in the future (in particular, yywrap() will probably cease
	  to be a macro and instead be a function in the -lfl library).

	- Hexadecimal (\x) escape sequences added.

	- Support for MS-DOS, VMS, and Turbo-C integrated.

	- The %used/%unused operators have been deprecated.  They
	  may go away soon.


    Other changes:

	- Makefile enhanced for easier testing and installation.
	- The parser has been tweaked to detect some erroneous
	  constructions which previously were missed.
	- Scanner input buffer overflow is now detected.
	- Bugs with missing "const" declarations fixed.
	- Out-of-date Minix/Atari patches provided.
	- Scanners no longer require printf() unless FLEX_DEBUG is being used.
	- A subtle input() bug has been fixed.
	- Line numbers for "continued action" rules (those following
	  the special '|' action) are now correct.
	- unput() bug fixed; had been causing problems porting flex to VMS.
	- yymore() handling rewritten to fix bug with interaction
	  between yymore() and trailing context.
	- EOF in actions now generates an error message.
	- Bug involving -CFe and generating equivalence classes fixed.
	- Bug which made -CF be treated as -Cf fixed.
	- Support for SysV tmpnam() added.
	- Unused #define's for scanner no longer generated.
	- Error messages which are associated with a particular input
	  line are now all identified with their input line in standard
	  format.
	- % directives which are valid to lex but not to flex are
	  now ignored instead of generating warnings.
	- -DSYS_V flag can now also be specified -DUSG for System V
	  compilation.


Changes between 2.1 beta-test release of June '89 and previous release:

    User-visible:

	- -p flag generates a performance report to stderr.  The report
	  consists of comments regarding features of the scanner rules
	  which result in slower scanners.

	- -b flag generates backtracking information to lex.backtrack.
	  This is a list of scanner states which require backtracking
	  and the characters on which they do so.  By adding rules
	  one can remove backtracking states.  If all backtracking states
	  are eliminated, the generated scanner will run faster.
	  Backtracking is not yet documented in the manual entry.

	- Variable trailing context now works, i.e., one can have
	  rules like "(foo)*/[ \t]*bletch".  Some trailing context
	  patterns still cannot be properly matched and generate
	  error messages.  These are patterns where the ending of the
	  first part of the rule matches the beginning of the second
	  part, such as "zx*/xy*", where the 'x*' matches the 'x' at
	  the beginning of the trailing context.  Lex won't get these
	  patterns right either.

	- Faster scanners.

	- End-of-file rules.  The special rule "<<EOF>>" indicates
	  actions which are to be taken when an end-of-file is
	  encountered and yywrap() returns non-zero (i.e., indicates
	  no further files to process).  See manual entry for example.

	- The -r (reject used) flag is gone.  flex now scans the input
	  for occurrences of the string "REJECT" to determine if the
	  action is needed.  It tries to be intelligent about this but
	  can be fooled.  One can force the presence or absence of
	  REJECT by adding a line in the first section of the form
	  "%used REJECT" or "%unused REJECT".

	- yymore() has been implemented.  Similarly to REJECT, flex
	  detects the use of yymore(), which can be overridden using
	  "%used" or "%unused".

	- Patterns like "x{0,3}" now work (i.e., with lower-limit == 0).

	- Removed '\^x' for ctrl-x misfeature.

	- Added '\a' and '\v' escape sequences.

	- \<digits> now works for octal escape sequences; previously
	  \0<digits> was required.

	- Better error reporting; line numbers are associated with rules.

	- yyleng is a macro; it cannot be accessed outside of the
	  scanner source file.

	- yytext and yyleng should not be modified within a flex action.

	- Generated scanners #define the name FLEX_SCANNER.

	- Rules are internally separated by YY_BREAK in lex.yy.c rather
	  than break, to allow redefinition.

	- The macro YY_USER_ACTION can be redefined to provide an action
	  which is always executed prior to the matched rule's action.
	
	- yyrestart() is a new action which can be used to restart
	  the scanner after it has seen an end-of-file (a "real" one,
	  that is, one for which yywrap() returned non-zero).  It takes
	  a FILE* argument indicating a new file to scan and sets
	  things up so that a subsequent call to yylex() will start
	  scanning that file.

	- Internal scanner names all preceded by "yy_"

	- lex.yy.c is deleted if errors are encountered during processing.

	- Comments may be put in the first section of the input by preceding
	  them with '#'.



    Other changes:

	- Some portability-related bugs fixed, in particular for machines
	  with unsigned characters or sizeof( int* ) != sizeof( int ).
	  Also, tweaks for VMS and Microsoft C (MS-DOS), and identifiers all
	  trimmed to be 31 or fewer characters.  Shortened file names
	  for dinosaur OS's.  Checks for allocating > 64K memory
	  on 16 bit'ers.  Amiga tweaks.  Compiles using gcc on a Sun-3.
	- Compressed and fast scanner skeletons merged.
	- Skeleton header files done away with.
	- Generated scanner uses prototypes and "const" for __STDC__.
	- -DSV flag is now -DSYS_V for System V compilation.
	- Removed all references to FTL language.
	- Software now covered by BSD Copyright.
	- flex will replace lex in subsequent BSD releases.