Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

parser

Status
Not open for further replies.

malladisk

Programmer
Jun 14, 2001
69
0
0
US
Hi, is there any free parser program available for C++ which checks the syntax for things like missing ; or unmatched elses etc?
Thanks,
Sashi
 
No, but you could probably make one without too much difficulty. After all, programming is our job
 
Aah, yes [cheers] here's to laziness!

"The greatest virtues of the programmer are laziness, impatience and hubris." - Larry Wall, creator of Perl

LAZINESS: The quality that makes you go to great effort to reduce overall energy expenditure. It makes you write labor-saving programs that other people will find useful, and document what you wrote so you don't have to answer so many questions about it. Hence, the first great virtue of a programmer.

IMPATIENCE: The anger you feel when the computer is being lazy. This makes you write programs that don't just react to your needs, but actually anticipate them. Or at least that pretend to. Hence, the second great virtue of a programmer.

HUBRIS: Excessive pride, the sort of thing Zeus zaps you for. Also the quality that makes you write (and maintain) programs that other people won't want to say bad things about. Hence, the third great virtue of a programmer.

-- Randal Schwartz, The Camel Book


As for the actual answer of your question, I think the C++ compiler itself might do the trick. Invoke CL.EXE with command line parameters that tell it to build to a useless object file somewhere, then delete the object file. Use the stdout and stderr to find out about your errors and warnings.

Let me know if this works for you.
 
hmm, cl.ex.. what wah that? too much work...
I was just looking for something that will put nested lines on the left margin for easy identifaction of code blocks. But that's ok, I got my bug fixed (which caused my detour to tek-tips in the first place).
Thanks for your help, though.
Sashi.
 
Status
Not open for further replies.

Similar threads

Part and Inventory Search

Sponsor

Back
Top