mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
ops: use ARRAY_SIZE macro for opchars array length
This commit is contained in:
parent
d8d4f05564
commit
5cf96fc141
@ -153,7 +153,7 @@ int get_op_type(int char1, int char2)
|
|||||||
if (opchars[i][0] == char1 && opchars[i][1] == char2) {
|
if (opchars[i][0] == char1 && opchars[i][1] == char2) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (i == (int)(sizeof(opchars) / sizeof(char [3]) - 1)) {
|
if (i == (int)(ARRAY_SIZE(opchars) - 1)) {
|
||||||
internal_error("get_op_type()");
|
internal_error("get_op_type()");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user