Skip to content

fix(stack-parser): fix source code lines iterations #120

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 2, 2025

Conversation

e11sy
Copy link
Contributor

@e11sy e11sy commented Apr 1, 2025

Problem

If we use

for (i in list.slice(startIndex, endIndex)) {}

i gets values from 0 to (endIndex - startIndex)
this is why we were getting this broken stack trace (source code lines were just indexes)
image

Solution

  • Used list.slice(start, end).forEach(i => {})

@e11sy e11sy merged commit e213af2 into master Apr 2, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants