Wednesday, 2 April 2014

Source Code Parsing

Below you will see an Blog Post written by Mahesha Pandit, we found it really interesting to read about ourself tool someone else's perspective;
 
"I was trying to explain how the Objektum Legacy Explorer works to a bunch of architects from a leading system integration company. During this interaction, all sorts of terms and phrases such as “source code parser”, “semantic checker”, “grammar cannot be parsed” etc. were being used. I was cursing myself for being the only one who has studied computer science.

We were trying to learn how to write a BNF grammar to parse a source code written in a particular language.

Saying that the grammar is also a source code, I was inviting participants not to use the phrase “source code parsing” loosely. I gave up after a while.

“Source code parser” – in my opinion parser, er, source code (what else!). Its objective is to detect syntax errors etc.

The tool in question had a formal BNF grammar – which itself is parsed and compiled. When the tool runs on the input source code text, it is the parsing engine (which is – very simply understood as – the compiled grammar) that parses the source code to output meta-data.

I understand the participant’s view that the whole tool is nothing but the “source code parser”. But facts such as grammar needs validation, grammar needs compilation, parsing engine parses source code, BNF grammar is also a source code for the tool etc. rush through my head forcing the nerd within me to abstract out all of the complexity, smile and accept.

I realised one more thing - Understanding is different from appreciation. In most cases, we understand but don't appreciate certain things."
 
Original Source: Mahesha's Blog

Thanks for Reading
 

No comments :

Post a Comment