![]() Time taken to recognize and partition an input stream is proportional to the length of the input.Generates a deterministic finite automaton from regular expressions.Yacc creates parsers that accepts a large class of context-free grammars Lexical Rules Grammar Rules X X X X yyparse yylex YACC LEX Input Parsed Input. ![]() Lex programs recognize only regular expressions.Can also be used with a parser generator.Recognize expressions in input and perform specified actions for each SOURCE LEX YYLEX YYLEX INPUT OUTPUT.User’s expressions and actions are converted into output general-purpose language.Can write code in different host languages.Generator representing a new language feature.Associates regular expressions and program fragments.Partition the input stream into strings matching the regular expressions.Grammar : set of rules that define the relationships.Takes a set of descriptions of tokens and produces a C routine – Lexical Analyzer.Discovering the relationship among them.Dividing the program into meaningful units.Two tasks in programs with structured input.Control flow is directed by instances of regular expressions.Help to write programs that transform structured input.
0 Comments
Leave a Reply. |