| | |
New Parser Generator
Please support our Computer Science advertiser: Learn about neural networks and artificial intelligence.
![]() |
•
•
Join Date: Dec 2008
Posts: 7
Reputation:
Solved Threads: 0
Come on. Please don't insult me. Look, I fixed the file up at the link I had given you - sorry I was careless about leaving gets out.
http://www.uweb.ucsb.edu/~frenchenee...Calculator.cpp
That does use gets, and it doesn't work properly. I shouldn't have said "crash" - that was misleading. The string is not recognized by my parser for some reason, and it fails. Commenting out fgets, and using my code makes it work. I don't believe there is any logical error. This is why I assumed something was wrong with the compiler.
Why? I would be very surprised if 'gets' didn't use 'fgets' under the covers.
http://www.uweb.ucsb.edu/~frenchenee...Calculator.cpp
That does use gets, and it doesn't work properly. I shouldn't have said "crash" - that was misleading. The string is not recognized by my parser for some reason, and it fails. Commenting out fgets, and using my code makes it work. I don't believe there is any logical error. This is why I assumed something was wrong with the compiler.
•
•
•
•
Instead of using gets, you should use fgets.
![]() |
Similar Threads
- simple calculator using a scanner (re2c) and a parser generator (lemon) (C)
- xml to object and vice versa (Java)
- Visual C++ and Lex/Yacc (IT Professionals' Lounge)
- Why are there so many languages? (Computer Science)
- Oracle and PostreSQL grammar classes (Computer Science)
- XHTML Complient parser? (HTML and CSS)
Other Threads in the Computer Science Forum
- Previous Thread: flowchart done needs help ...take a look
- Next Thread: I need some tips on creating a flowchart.
| Thread Tools | Search this Thread |
ai algorithm algorithms amazon assignment assignmenthelp assignments automata battery bigbrother binary bittorrent bizarre bletchleypark blogging bomb business cern codebreaker compiler computer computers computerscience computertrackingsoftware connect conversion csc dataanalysis dataintepretation development dfa dissertation dissertations dissertationthesis dissertationtopic ebook employment energy floatingpoint foreclosure foreclosuresoftware fuel gadgets geeks givemetehcodez government hardware history homeworkassignment homeworkhelp humor ibm idea ideas internet iphone ipod itcontracts jobs kindle laser laws linkbait lsmeans mainframes marketing mobileapplication nano netbeans networking news os p2p piracy piratebay principles programming rasterizer research sam-being-cute sas science security sex simulation software spying stephenfry study supercomputer supercomputing sweden technology textfield turing turingtest two'scompliment uk virus ww2






