Skip to content

Conversation

@rocky
Copy link
Collaborator

@rocky rocky commented Dec 6, 2024

Towards addressing problem in screenshot 1. Regression tests fail, so more work is needed.

@rocky rocky marked this pull request as draft December 6, 2024 02:48
@rocky rocky requested a review from jansorg December 6, 2024 02:49
Copy link
Collaborator

@jansorg jansorg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for working on this!
When I run this branch with my test sources, then I'm seeing this error.
I looked at it, but couldn't spot the problem.
For my review, only minor notes so far.

[jansorg@Island sources]$ ../../bashdb --style colorful -L ../.. main.bash 
bash debugger, bashdb, release 5.2-1.1.2

Copyright 2002-2004, 2006-2012, 2014, 2016-2019, 2021, 2023-2024 Rocky Bernstein
This is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.

** Internal debug error _Dbg_is_file(): file argument null
../../lib/filecache.sh: Zeile 247: _Dbg_filenames["$fullname"]: Falscher Feldindex.
hello world
Debugged program terminated normally. Use q to quit or R to restart.
bashdb<0> 

adjusted_pos=$(_Dbg_frame_adjusted_pos 0)
filename=$(_Dbg_file_canonic "${BASH_SOURCE[$adjusted_pos]}")
filename="${BASH_SOURCE[$adjusted_pos]}"
resolved_filename="${_Dbg_file2canonic[$filename]}"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this have a local or typeset?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you are correct. Should be corrected now.

lib/file.sh Outdated
typeset dirname="${_Dbg_dir[i]}"
if [[ "$basename" == '\$cdir' ]] ; then
basename=$_Dbg_cdir
dirname=$_Dbg_cdir
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quotes?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you are correct. Should be handled now.

lib/file.sh Outdated
dirname=$_Dbg_cdir
elif [[ "$basename" == '\$cwd' ]] ; then
basename=$(pwd)
dirname=$(pwd)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quotes?

Copy link
Collaborator Author

@rocky rocky Dec 7, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you are correct; this should be handled now.

rocky and others added 2 commits December 7, 2024 12:30
@rocky
Copy link
Collaborator Author

rocky commented Dec 8, 2024

Superseded by #54

@rocky rocky closed this Dec 8, 2024
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.

3 participants