FLEX(1)
๐ FLEX(1) โ the flex page, bestie ๐
okay so this is the Programming section, the title is FLEX(1), and the manual name is flex โ the fast lexical analyser generator. She's iconic, she's useful, and we're getting into every single flag. ๐ซถ
โจ NAME โจ
flex โ the fast lexical analyser generator. That's the whole name section, bestie. ๐
๐ธ SYNOPSIS ๐ธ
flex [OPTIONS] [FILE]...
That's the whole vibe: you run flex with options and files. โจ
๐ DESCRIPTION ๐
Generates programs that perform pattern-matching on text. That's the core, and the rest is all the knobs, dials, and little details. ๐ฆ
๐ Table Compression ๐
-Ca,--alignโ trade off larger tables for better memory alignment-Ce,--ecsโ construct equivalence classes-Cfโ do not compress tables; use-frepresentation-CFโ do not compress tables; use-Frepresentation-Cm,--meta-ecsโ construct meta-equivalence classes-Cr,--readโ useread()instead ofstdiofor scanner input-f,--fullโ generate fast, large scanner. Same as-Cfr-F,--fastโ use alternate table representation. Same as-CFr-Cemโ default compression (same as--ecs --meta-ecs)
๐ Debugging ๐
-d,--debugโ enable debug mode in scanner-b,--backupโ write backing-up information tolex.backup-p,--perf-reportโ write performance report tostderr-s,--nodefaultโ suppress default rule toECHOunmatched text-T,--traceโflexshould run in trace mode-w,--nowarnโ do not generate warnings-v,--verboseโ write summary of scanner statistics tostdout--hexโ use hexadecimal numbers instead of octal in debug outputs
๐ FILES ๐
okay the page labels this whole next chunk FILES, and we're keeping the order exactly as she wrote it. No notes. ๐
-o,--outfile=FILEโ specify output filename-S,--skel=FILEโ specify skeleton file-t,--stdoutโ write scanner onstdoutinstead oflex.yy.c--yyclass=NAMEโ name of C++ class--header-file=FILEโ create a C header file in addition to the scanner--tables-file[=FILE]โ write tables toFILE
๐ Scanner behavior ๐
-7,--7bitโ generate 7-bit scanner-8,--8bitโ generate 8-bit scanner-B,--batchโ generate batch scanner (opposite of-I)-i,--case-insensitiveโ ignore case in patterns-l,--lex-compatโ maximal compatibility with originallex-X,--posix-compatโ maximal compatibility with POSIXlex-I,--interactiveโ generate interactive scanner (opposite of-B)--yylinenoโ track line count inyylineno
๐ Generated code ๐
-+,--c++โ generate C++ scanner class-Dmacro[=defn]โ#define macro defn (default defn is '1')-L,--nolineโ suppress#linedirectives in scanner-P,--prefix=STRINGโ useSTRINGas prefix instead of"yy"-R,--reentrantโ generate a reentrant C scanner--bison-bridgeโ scanner for bison pure parser.--bison-locationsโ includeyyllocsupport.--stdinitโ initializeyyin/yyouttostdin/stdout--nounistdโ do not include<unistd.h>--noFUNCTIONโ do not generate a particularFUNCTION
๐ Miscellaneous ๐
-cโ do-nothing POSIX option-nโ do-nothing POSIX option-?โ (the page gives no description for this one, bestie)-h,--helpโ produce this help message-V,--versionโ reportflexversion
๐ SEE ALSO ๐
The full documentation for flex is maintained as a Texinfo manual. If the info and flex programs are properly installed at your site, the command
info flex
should give you access to the complete manual. โจ
๐ซถ okay that's the page โ footer sign-off vibes: The Flex Project ยท February 2024 ยท FLEX(1). Mwah. ๐
๐ฆ where this page comes from
- opensuse-leap 16.0: flex 2.6.4-160000.2.2 ยท BSD-3-Clause
- opensuse-leap 16.0: flex 2.6.4-160000.2.2 ยท BSD-3-Clause
- opensuse-leap 16.0: flex 2.6.4-160000.2.2 ยท BSD-3-Clause
- opensuse-leap 16.0: flex 2.6.4-160000.2.2 ยท BSD-3-Clause
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms