byacc - Exception trapped

Earnie Boyd earnie_boyd@hotmail.com
Thu Oct 2 10:09:00 GMT 1997


This should be simple:

I wanted to learn lex & yacc.  So I bought the O'Reilly & Associates 
book.  I begin compiling and linking the examples.  Things are looking 
good and working fine; until, I get to the yacc section in chapter 1.

I have the lex examples coded from Example 1.6 and the yacc examples 
coded from Example 1.7 and 1.8.  I then do:

    flex ch1-05.flex
    byacc ch1-05.byacc
    gcc -c lex.yy.c y.tab.c
    gcc -o ch1-05 lex.yy.o y.tab.o -lfl

Now here is where the problem starts:
I execute ch1-05 and get the attached dump. 8^(

I've also attached the flex and byacc source files.


Does anyone have a solution?

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com
ch1_05_error
ch1_05_byacc
ch1_05_flex
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ch1_05_byacc
Type: text/x-c
Size: 522 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin/attachments/19971002/8d1fb693/attachment.bin>
-------------- next part --------------
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) In cygwin_except_handler
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) Exception trapped!
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) exception C0000005 at 402C75
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) exception: ax 0 bx 0 cx 10047814 dx 0
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) exception: si 5 di 1000B8B3 bp 240F01C sp 240F01C
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) exception is: STATUS_ACCESS_VIOLATION
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) Stack trace:
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 0: sp = 0x240EE58, pc = 0x1000CEC2
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 1: sp = 0x240EE74, pc = 0x77FA9182
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 2: sp = 0x240EE98, pc = 0x77FA037B
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 3: sp = 0x240EF1C, pc = 0x77F903C2
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 4: sp = 0x240F01C, pc = 0x1000C102
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 5: sp = 0x240FFC4, pc = 0x1000C113
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 6: sp = 0x240FFD0, pc = 0x4032F1
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 7: sp = 0x240FFE0, pc = 0x40103B
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) frame 8: sp = 0x240FFF0, pc = 0x0
(c:\users\bcoeeb0\My Projects\learn\lex\ch1-05.exe 4057) End of stack trace
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ch1_05_flex
Type: text/x-c
Size: 2854 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin/attachments/19971002/8d1fb693/attachment-0001.bin>


More information about the Cygwin mailing list