flex icon indicating copy to clipboard operation
flex copied to clipboard

flex: input rules are too complicated (>= 32000 NFA states)"

Open nIxedoahz opened this issue 1 year ago • 3 comments

flex version 2.6.4

Error reported as follows

flex: input rules are too complicated (>= 32000 NFA states)"

How do I solve this problem without generating cpp files

nIxedoahz avatar Jun 16 '23 02:06 nIxedoahz

That's a fun error. Can you share your input file?

Mightyjo avatar Jun 16 '23 02:06 Mightyjo

That's a fun error. Can you share your input file?

#define MAXIMUM_MNS 31999 If I modify this macro to: #define MAXIMUM_MNS 319999 Will it cause any problems

nIxedoahz avatar Jun 16 '23 03:06 nIxedoahz

It's a performance parameter for the Flex generation process. Increasing it might let Flex exhaust your system memory or make it take a very long time to produce your scanner.

It's hard to predict whether the generated scanner would be noticably slow or unusually large.

Did you try it? If so, what happened?

Mightyjo avatar Sep 13 '23 13:09 Mightyjo