Visual C++ and Lex/Yacc

Reply

Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Visual C++ and Lex/Yacc

 
0
  #1
May 17th, 2007
I want to write a parser for C++ which can extract methods and members pertaining to a particular class(es) in a CPP file. I used Parser Generattor tool by BumbleBee softwares and did all the project settings as required by them but still keep on getting fatal errors in Exception Class(of Visual Studio 6 Library).

Is there a proper tool wherein I can integrate lex and yacc with VC++ 6.0.

Urgent Help Required. Please help
Regards
Shouvik
Reply With Quote Quick reply to this message  
Join Date: May 2006
Posts: 1,824
Reputation: ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all ithelp is a name known to all 
Solved Threads: 117
ithelp's Avatar
ithelp ithelp is offline Offline
Posting Virtuoso

Re: Visual C++ and Lex/Yacc

 
0
  #2
May 17th, 2007
Why not code in linux/unix env?
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Re: Visual C++ and Lex/Yacc

 
0
  #3
May 17th, 2007
I can't shift to Linux becoz my existing project is in VC++ 6.0 and I've to add parsing functionality to it. Hence you can see the problem here.
Regards
Shouvik
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 15,358
Reputation: Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute Ancient Dragon has a reputation beyond repute 
Solved Threads: 1463
Team Colleague
Featured Poster
Ancient Dragon's Avatar
Ancient Dragon Ancient Dragon is offline Offline
Still Learning

Re: Visual C++ and Lex/Yacc

 
0
  #4
May 17th, 2007
maybe you should contact BumbleBee. Also possible that VC++ 6.0 is too old. You might try a more current compiler such as the free VC++ 2005 Express.
Don't PM me with questions -- you might get a nasty PM in response. If you have a question then post it in one of the forums.
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 2,039
Reputation: Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice 
Solved Threads: 139
Team Colleague
Rashakil Fol's Avatar
Rashakil Fol Rashakil Fol is offline Offline
Super Senior Demiposter

Re: Visual C++ and Lex/Yacc

 
0
  #5
May 17th, 2007
Perhaps you could use the Spirit parser combinator library instead.
All my posts may be redistributed under the GNU Free Documentation License.
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Re: Visual C++ and Lex/Yacc

 
0
  #6
May 18th, 2007
Well the problem is not with Bumblebee. When I used a sample project from SampleCodeForLex/Yacc then also I faced the same error as mentioned below.

error C2440: '=' : cannot convert from 'struct _iobuf *' to 'class std::basic_istream<char,struct std::char_traits<char> > *'

for the code line
FILE   *temp,
         *f;
lexer.yyin = f;

lexer is the object of the class CLexRC wherein CLexRC loks like this in first line of the class
class YYEXPLEXER YYFAR CLexRC : public _YL yyclexer {

please help.
Regards
Shouvik
Reply With Quote Quick reply to this message  
Join Date: Jun 2005
Posts: 2,039
Reputation: Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice Rashakil Fol is just really nice 
Solved Threads: 139
Team Colleague
Rashakil Fol's Avatar
Rashakil Fol Rashakil Fol is offline Offline
Super Senior Demiposter

Re: Visual C++ and Lex/Yacc

 
0
  #7
May 18th, 2007
It's assigning an uninitialized FILE* to another value? There's something wrong with that picture. Anyway, it looks like the yyin member is of type std::basic_istream<char, struct std::char_traits<char> >*, and the code is trying to assign a FILE* to it. At least, that's what the error message says.
All my posts may be redistributed under the GNU Free Documentation License.
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Re: Visual C++ and Lex/Yacc

 
0
  #8
May 18th, 2007
so how to type cast it. I'm understanding the error but as a matter of fact the CPP file is not manually written. it gets generated by Bumblebee Parser Generator. I saw this kind of file stream assignment to most of the projects

What shall I do ?
Regards
Shouvik
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Re: Visual C++ and Lex/Yacc

 
0
  #9
Jun 5th, 2007
I'm now able to run lex files fine but while utilizing the yacc stack descriptors like '$$' it is giving the following error:

warning Y4003: '$$' : attribute is untyped

thought this is a warning now. If I'm assigning anything to it or trying to use string copy then it is throwing an error.

please help.
Regards
Shouvik
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 200
Reputation: shouvik.d is an unknown quantity at this point 
Solved Threads: 6
shouvik.d's Avatar
shouvik.d shouvik.d is offline Offline
Posting Whiz in Training

Re: Visual C++ and Lex/Yacc

 
0
  #10
Jun 7th, 2007
please help. I'm not able to $$ at all. the error Untyped Attribute is repeated at any case.

PLease help me it is kind of urgent.
Regards
Shouvik
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the IT Professionals' Lounge Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC