lukeparser/pybison

Segmentation Fault

Opened this issue · 1 comments

Hi, I try to run example of json again , command give error message like that:

2021-01-26 16:14:59,602 [DEBUG] bison.bison_: call def possible_so
2021-01-26 16:14:59,603 [DEBUG] bison.bison_: call def openLib
2021-01-26 16:14:59,603 [DEBUG] bison.bison_: Opening library /tmp/pybison/pybison_JSONParser/JSONParser_engine.cpython-39-x86_64-linux-gnu.so
bisondynlib_open: /tmp/pybison/pybison_JSONParser/JSONParser_engine.cpython-39-x86_64-linux-gnu.so
2021-01-26 16:14:59,604 [INFO] bison.bison_: Successfully loaded library
2021-01-26 16:14:59,604 [DEBUG] bison.bison_: b'ec643594ef2341f805c284e7b941054a7004b924'
2021-01-26 16:14:59,604 [INFO] bison.bison_: Hashes match, no need to rebuild bison engine lib
instantiate parser 0.0026242733001708984
json 0.00013113021850585938
Parser.run: calling engine
2021-01-26 16:14:59,604 [DEBUG] bison.bison_: call def runEngine
Parser.read: want 8192 bytes
Parser.read: got 14 bytes
b'{"web-app": {\n'
段错误 (核心已转储)

I try to debug this problem. so I have add #22 and #21 PR for this problem

Hey @x007007007,

I added a short introduction on debugging a parser with gdb, I hope this helps!

As a note: the examples are outdated (old grammar / lexer files) and need some love.