gdb/fortran: Cleanup code for parsing logical constants
This patch cleans up the code used for parsing the Fortran logical
constants '.TRUE.' and '.FALSE.'. Instead of listing both upper and
lowercase versions of these strings we now use strncasecmp.
I've also switched to use ARRAY_SIZE for the array iteration, and I've
cleaned up whitespace in the vicinity of the code I've changed.
Finally, I've added a test to ensure that both the upper and lower
case versions of the logical constants are understood by GDB,
something that was missing previously.
There should be no user visible changes after this commit.
gdb/ChangeLog:
* f-exp.y (struct f77_boolean_val): Add comments.
(boolean_values): Remove uppercase versions, and end marker.
(yylex): Use ARRAY_SIZE for iterating over boolean_values array,
and use strncasecmp to achieve case insensitivity. Additionally,
perform whitespace cleanup around this code.
gdb/testsuite/ChangeLog:
* gdb.fortran/types.exp (test_logical_literal_types_accepted):
Check upper and lower case logical literals.