Open andychu opened 4 years ago
@akinomyoga Thanks for tracking this down!
I would like to make sure the output of everything is parseable. I don't like bash's inconsistency though, for example set -o
gives one format and shopt -o -p
gives another format. I feel the trap format is similarly inconsistent.
So let's leave this issue until the rest of the issues on #653 are addressed, unless you think it's blocking something now
Thank you for the report! But
EXIT
andRETURN
must not appear here in originalble.sh
. It seems there are some problems in upstream of the code, which causes the wrong values of$index
.Ah, this is caused by the format difference of
trap -l
between Bash and Oil. Looking at Oiltrap -l
outputs,ble.sh
considersEXIT
to be the value ofERR
andRETURN
to be the value ofDEBUG
.Originally posted by @akinomyoga in https://github.com/oilshell/oil/issues/664#issuecomment-602005629