Commit a6e840d
committed
Fix file path and line number errors when using
This PR fix file path and line number errors when using `+`, `*` or `()`.
I discovered this when using the above new grammar in Lrama.
Refs: ruby/lrama@df39a6f
Refs: https://github.com/ruby/lrama/blob/df39a6f36535ac65e08a0a49eb84d6b944622e22/lib/lrama/parser.rb#L1270-L1282
As it stands, the second argument to `module_eval` is the absolute path to racc/grammarfileparser.rb and the line number. Perhaps specifying `@filename` and` @scanner.lineno + 1` is correct?
https://github.com/ydah/racc/blob/ea43e57012355c726b914c52fdcb32708d1091c6/lib/racc/grammarfileparser.rb#L373+, * and ()
1 parent d27b781 commit a6e840d
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
295 | 295 | | |
296 | 296 | | |
297 | 297 | | |
298 | | - | |
| 298 | + | |
299 | 299 | | |
300 | 300 | | |
301 | 301 | | |
| |||
308 | 308 | | |
309 | 309 | | |
310 | 310 | | |
311 | | - | |
| 311 | + | |
312 | 312 | | |
313 | 313 | | |
314 | 314 | | |
| |||
323 | 323 | | |
324 | 324 | | |
325 | 325 | | |
326 | | - | |
| 326 | + | |
327 | 327 | | |
328 | 328 | | |
329 | 329 | | |
| |||
0 commit comments