A Parser is the a part of a Compiler that breaks Source Code into small sections of Character Strings called Tokens.
The term has its Roots in linguistics. In linguistics, parsing involves bodily diagraming the underlying structure of a sentence. The reason is to assist the learner recognize the Context of each sentence detail and its Relationship to the meaning of the sentence.
In Computing, parsers create logical diagrams called trees. The reason is to help the Compiler understand the context of each token and its courting to the underlying shape of the supply Code.
Parsers are extensively used within the following technologies:
Java and different Programming Languages.
HTML and XML.
Database languages such as SQL.
Modeling Languages, which include Digital fact Modeling language (VRML).
Scripting Languages along with JavaScript.
Protocols, including HTTP.
The technical sySTEM of parsing has 3 degrees:
Lexical Analysis: produces tokens from a stream of enter Characters. A token is the smallest uNit in A Programming Language that possesses a few that means (which includes , -, *, “Function”, or “new” in JavaScript).
Syntactic Analysis: tests to see if the generated tokens Form a meaningful Expression.
Semantic Parsing: uses Syntax Bushes and symbol appearance-up Tables to decide whether the generated tokens are semantically regular with a specifiC Programming Language.
Parsing may be performed in both a pinnacle-down or bottom-up manner.
Top-Down Parsing: Parsing starts with the start image and trees are Constructed from root to leaves. Top-down parsing is also called predictive parsing or recursive parsing.
Bottom-Up Parsing: Trees are built from leaves to root and ends with the begin image. This sort of parsing is likewise called shift-lessen parsing.
Your Score to Parser article
Score: 5 out of 5 (1 voters)
Be the first to comment on the Parser
tech-term.com© 2023 All rights reserved