Misidentification of arithmetic expansions
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 14.2k
- Forks
- 851
- PR merge metrics
- No merged PRs in 30d
Description
Where the bash(1) reads
((expression))
The expression is evaluated according to the rules described
below under ARITHMETIC EVALUATION. If the value of the expres‐
sion is non-zero, the return status is 0; otherwise the return
status is 1. This is exactly equivalent to let "expression".
explainshell gives this instead:
(list) list is executed in a subshell environment (see COMMAND EXECU‐
TION ENVIRONMENT below). Variable assignments and builtin com‐
mands that affect the shell's environment do not remain in
effect after the command completes. The return status is the
exit status of list.
It's a great project btw. :)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the explainshell example command and compare its classification with the bash(1) manual text quoted in the issue. Trace how (( foo )) is parsed and matched against the arithmetic-expansion documentation versus (list), then verify that the example is identified correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bash, python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100