Updated SC1102 (markdown)

lacygoill
2022-09-26 19:33:14 +02:00
parent dd37d040d6
commit 02f5a5113e

@@ -1,4 +1,4 @@
## Shells disambiguate `$((` differently or not at all. For `$(command substition)`, add space after `$(` . For `$((arithmetics))`, fix parsing errors. ## Shells disambiguate `$((` differently or not at all. For `$(command substitution)`, add space after `$(` . For `$((arithmetics))`, fix parsing errors.
### Problematic code: ### Problematic code:
@@ -25,4 +25,4 @@ Ash, dash and Bash 1 parses it as `$(( (` and subsequently fail to find the matc
**Alternatively**, you may indeed have correctly spaced your parentheses, but ShellCheck failed to parse `$((` as an arithmetic expression while accidentally succeeding in parsing it as `$(` + `(`. **Alternatively**, you may indeed have correctly spaced your parentheses, but ShellCheck failed to parse `$((` as an arithmetic expression while accidentally succeeding in parsing it as `$(` + `(`.
In these cases, double check the syntax to ensure ShellCheck can parse the `$((`, or ignore this error and hope that it won't affect analysis too severely. In these cases, double check the syntax to ensure ShellCheck can parse the `$((`, or ignore this error and hope that it won't affect analysis too severely.