Techknow Study

Basic Parsing

9:49:00 AM vikas 0 Comments Category :

Basic Parsing

  •  What do you understand by parsing?
Parsing (also known as syntax analysis) can be defined as a process of scanning/analyzing a text which is collection tokens that are symbols, and then give it a grammatical structure
with respect to a given grammar.



On the bases, how the parse tree is built, Parsing techniques are further divide into three general categories, that are, universal parsing, top-down parsing, and bottom-up parsing. But the most commonly used parsing techniques are top-down parsing and bottom-up parsing. The first one “Universal parsing” is not used as it is not an efficient technique.

  • The role of a parser?
Role of a parser: In computer technology, a parser is a program, usually part of a compiler, that receives input in the form of sequential program/collection.

or

A parser receives a string of tokens from lexical analyzer and constructs a parse tree if the string of tokens can be generated by the grammar of the source language; otherwise, it reports the syntax errors present in the source string.

>>>>>>>>>>

RELATED POSTS

0 comments