Skip to content

fix(_get_comp_words_by_ref): work around localvar_inherit #796

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

Conversation

akinomyoga
Copy link
Collaborator

@akinomyoga akinomyoga commented Sep 3, 2022

I separate the change from #790 #791. This is the most independent part.

  • 868e98e work around localvar_inherit: This is actually not directly related to the refactoring of _command_offset, but I noticed this in investigating which variables can be modified by _comp_offset for 868e98e. The implementation of _get_comp_words_by_ref assumes that the declared variables vcur, vwords, vcword, and vprev have initially unset values to later test them with [[ -v vcur ]], etc., but this is not ensured when localvar_inherit is turned on.

The description is unchanged from that in #790 #791.

@akinomyoga akinomyoga force-pushed the _get_comp_words_by_ref-localvar_inherit branch from b908d06 to df7934d Compare September 3, 2022 12:11
@akinomyoga akinomyoga marked this pull request as ready for review September 3, 2022 12:11
@scop scop merged commit 9c061e5 into scop:master Sep 10, 2022
@akinomyoga akinomyoga deleted the _get_comp_words_by_ref-localvar_inherit branch September 12, 2022 12:59
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