diff --git a/SC2219.md b/SC2219.md index c23b4fd..d5ce9c3 100644 --- a/SC2219.md +++ b/SC2219.md @@ -9,8 +9,11 @@ let a++ ### Correct code: ```sh -(( a++ )) +(( a++ )) || true ``` + +> Note, `|| true` bits ignore error status code when incrementing from `0` to `1` + ### Rationale: The `(( .. ))` arithmetic compound command evaluates expressions in the same way as `let`, except it's not subject to glob expansion and therefore requires no additional quoting or escaping.