NetBSD/usr.bin/xlint
rillig 870d1f87f1 lint: extract code for determining possible precedence confusion
The function check_precedence_confusion was pretty long, and right in
the middle of that function was the complicated part of determining
which of the operand combinations are confusing and which aren't.

Extract this part into a separate function to document on which
information this decision is based.  This makes it easier to understand
the code since there are fewer local variables around.

As a left-over from a previous commit, rop and rparn don't need to be
initialized twice, now that the assertion for a binary operator is in
place.

Remove the large and useless switch statement over all operator types.
This list was completely unsorted, for no apparent reason.  To see the
list of operators, better look them up in ops.def, there was no need to
have this list duplicated here.
2021-01-05 00:17:21 +00:00
..
arch
common lint: fix typos and other minor stylistic issues 2021-01-04 22:26:50 +00:00
lint1 lint: extract code for determining possible precedence confusion 2021-01-05 00:17:21 +00:00
lint2 lint: fix typos and other minor stylistic issues 2021-01-04 22:26:50 +00:00
llib
xlint lint: fix typos and other minor stylistic issues 2021-01-04 22:26:50 +00:00
Makefile
Makefile.inc