flex-lexer
How do I write a non-greedy match in LEX / FLEX?
I\'m trying to parse a legacy language (which is similar to \'C\') using FLEX and BISON. Everything is working nicely except for matching strings.[详细]
2023-01-25 07:38 分类:问答Separating reserved identifiers in flex
I have a language I am making a parser for which contains function calls. A few function names are reserved and I would like to handle them differently in my grammer. In EBNF it would look like[详细]
2023-01-24 12:16 分类:问答How to get yacc/bison and lex/flex to pause file scanning?
Im trying to parse a file using Bison/Yacc but i want to pause the parsing for a while. The reason i want to do this is that i want to process a huge file sequentially and simulate a java iterator usi[详细]
2023-01-24 04:48 分类:问答Ubuntu: how to install flex to make postgres?
I\'m trying to work on postgresql local开发者_开发知识库ly with ubuntu 10.04. I get this error after I configure with[详细]
2023-01-18 17:04 分类:问答Returning "non-ints" from yylex
I have a generated scanner from flex which the output from is not consumed by yacc or bison. yylex() needs to returns a pointer to a token-like structure memory instead of an int indicating the token-[详细]
2023-01-17 09:52 分类:问答request for member in something not a structure or union
I\'ve been working for hours and I can\'t figure out how to print the token from the bison file, the bison file is thi开发者_如何学Pythons: (it\'s a short simple file)[详细]
2023-01-16 00:41 分类:问答Adding indentation
I\'m trying to make a parser for a made-up programming language. I\'m now at the part of the exercise where we\'re required to make sure the parser\'s output is a conversion in C of the input.[详细]
2023-01-13 01:46 分类:问答Trouble with printf in Bison Rule
I have tried something like this in my Bison file... ReturnS: RETURN expression {printf(\";\")} ...but the semicolon gets printed AFTER the next token, past this rule, instead of right after the ex[详细]
2023-01-12 19:14 分类:问答Using $x to grab string from rule
I\'m trying to do something like this in Bison... loop_for:FOR var_name COLONEQUALS expression TO {printf(\"%s<=\", $2);} expression STEP[详细]
2023-01-12 19:10 分类:问答Calling lex/yacc from a separate program
I\'ve been reading up on lex/yacc. The books and examples are not hard to follow. In fact, the whole concept is clear as a bell. With one exception. Lex/yacc seem to generate standalone programs. What[详细]
2023-01-12 17:21 分类:问答