You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An "index" function exists in strings.h, and older compilers (<GCC 4.8) warn if any local variables called "index" are used because they are considered to shadow that declaration. This issue broke our builds before #2540, and we almost introduced the same bug in #2589 (comment).
"index" is a reasonable variable name in other languages, and we'll probably make this mistake again. We should detect and prevent it with a linter.
Solution:
We can add a check for "index" to grep_simple_mistakes.sh, which runs against every pull request.
The text was updated successfully, but these errors were encountered:
Problem:
An "index" function exists in strings.h, and older compilers (<GCC 4.8) warn if any local variables called "index" are used because they are considered to shadow that declaration. This issue broke our builds before #2540, and we almost introduced the same bug in #2589 (comment).
"index" is a reasonable variable name in other languages, and we'll probably make this mistake again. We should detect and prevent it with a linter.
Solution:
We can add a check for "index" to grep_simple_mistakes.sh, which runs against every pull request.
The text was updated successfully, but these errors were encountered: