?
Solved

Syntax Analyzer(Parser) for C++

Posted on 1998-10-16
12
Medium Priority
?
2,793 Views
Last Modified: 2012-05-04
What Parsing technique is used in Turbo C++ Compiler.
What type of error recovery is used in Turbo C++ Compiler.
Is any site you know from where i can find Source Code of Compiler or even Parser of Turbo/Borland C++ coded in C++.
0
Comment
Question by:kashifmasood
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
  • +5
12 Comments
 
LVL 5

Expert Comment

by:scrapdog
ID: 1175296
I think if you pay Borland $1000000, they might let you *peek* at the source code...
0
 
LVL 1

Expert Comment

by:messiah
ID: 1175297
Intense parsing
Intense error recovery

$1,000,000 might get you a glimpse, but if you are ready and willing, go to the president of Borland with a cigar and go from there.

Trying to write a compiler is tedious and a pain in the ass. Once you get past the parsing, you have to generate decent optimized asm code out of the language, it's not an easy task.
0
 
LVL 6

Expert Comment

by:thresher_shark
ID: 1175298
I tried writing my own INTERPRETER, that is, there were no EXEs.  Wow, what a pain.  It worked okay, even fairly fast, but it was not worth the effort (the language was more cryptic that assembly and it was slower than BASIC)! :-)

What do you want to accomplish?  If this is for fun, then by all means try it, but otherwise, I fail to see the point :-)
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Expert Comment

by:dinom
ID: 1175299
Who cares?  If you really want to dive into a good C++ compiler's source, check out gcc.  Pick up a good book on compiler design too.  You could get lost in there for years.
0
 

Author Comment

by:kashifmasood
ID: 1175300
Adjusted points to 150
0
 

Author Comment

by:kashifmasood
ID: 1175301
Dear Friends
 I will be fair and thankful in the case of satisfactory answer

0
 
LVL 5

Expert Comment

by:scrapdog
ID: 1175302
http://www.first.gmd.de/cogent/catalog/

This site doesn't have a C++ compiler that I know of, but it contains some useful info that might be of interest to you.
0
 

Expert Comment

by:eric_m
ID: 1175303
Visual Parse++ looks promising.  Check out:

http://www.sand-stone.com/frvpdesc.htm

Search the web for bison, lex, flex, yacc, byacc, and you'll
find other parsing tools, as well.

Chances are good that Borland uses its own custom parser.
Chances are also good that you won't find out.  :)

0
 
LVL 84

Expert Comment

by:ozo
ID: 1175304
If you get a job programming for Borland, they might pay you to peek at the source code.
0
 
LVL 6

Expert Comment

by:thresher_shark
ID: 1175305
ozo - haha good way to put it :-)
0
 
LVL 2

Accepted Solution

by:
mnguyen021997 earned 450 total points
ID: 1175306
pccts is the best known pd c++ parser

http://www.idiom.com/free-compilers/TOOL/BNF-5.html
0
 

Author Comment

by:kashifmasood
ID: 1175307
messaih's aswer is better than mnguyen
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question