arnodel / golua

A Lua compiler / runtime in Go
Apache License 2.0
93 stars 10 forks source link

Implement line debug hook #74

Closed arnodel closed 2 years ago

arnodel commented 2 years ago

The debug hook on each code line was not implemented. This PR does it.

See https://www.lua.org/manual/5.4/manual.html#pdf-debug.sethook for details about the debug hook functionality in Lua.

codecov[bot] commented 2 years ago

Codecov Report

Merging #74 (570a45a) into master (2de00db) will increase coverage by 0.98%. The diff coverage is 57.14%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #74      +/-   ##
==========================================
+ Coverage   86.21%   87.19%   +0.98%     
==========================================
  Files          90       90              
  Lines        9822     9833      +11     
==========================================
+ Hits         8468     8574     +106     
+ Misses       1067      969      -98     
- Partials      287      290       +3     
Impacted Files Coverage Δ
runtime/debughooks.go 74.28% <40.00%> (+40.95%) :arrow_up:
runtime/luacont.go 90.21% <66.66%> (+0.99%) :arrow_up:
lib/debuglib/debuglib.go 98.94% <0.00%> (+28.42%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 2de00db...570a45a. Read the comment docs.