summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1998-08-15 14:21:00 +0000
committerJim Meyering <jim@meyering.net>1998-08-15 14:21:00 +0000
commit63d64851b12213a2d87dc8fe7bf11186421baa40 (patch)
tree3affaed0098eaef4fc62da0a92e529501599ee04 /src
parentd68269bb5503396a35f9c42f4455d860e8bcafa2 (diff)
downloadcoreutils-63d64851b12213a2d87dc8fe7bf11186421baa40.tar.xz
Add braces to suppress warning about ambiguous `else'.
Diffstat (limited to 'src')
-rw-r--r--src/ptx.c72
1 files changed, 38 insertions, 34 deletions
diff --git a/src/ptx.c b/src/ptx.c
index 7f5263aab..c77c824f6 100644
--- a/src/ptx.c
+++ b/src/ptx.c
@@ -504,24 +504,26 @@ initialize_regex (void)
if (word_regex_string && *word_regex_string)
word_regex = alloc_and_compile_regex (word_regex_string);
else if (!break_file)
- if (gnu_extensions)
- {
+ {
+ if (gnu_extensions)
+ {
- /* Simulate \w+. */
+ /* Simulate \w+. */
- for (character = 0; character < CHAR_SET_SIZE; character++)
- word_fastmap[character] = isalpha (character) ? 1 : 0;
- }
- else
- {
+ for (character = 0; character < CHAR_SET_SIZE; character++)
+ word_fastmap[character] = isalpha (character) ? 1 : 0;
+ }
+ else
+ {
- /* Simulate [^ \t\n]+. */
+ /* Simulate [^ \t\n]+. */
- memset (word_fastmap, 1, CHAR_SET_SIZE);
- word_fastmap[' '] = 0;
- word_fastmap['\t'] = 0;
- word_fastmap['\n'] = 0;
- }
+ memset (word_fastmap, 1, CHAR_SET_SIZE);
+ word_fastmap[' '] = 0;
+ word_fastmap['\t'] = 0;
+ word_fastmap['\n'] = 0;
+ }
+ }
}
/*------------------------------------------------------------------------.
@@ -1706,30 +1708,32 @@ static void
output_one_dumb_line (void)
{
if (!right_reference)
- if (auto_reference)
- {
+ {
+ if (auto_reference)
+ {
- /* Output the `reference' field, in such a way that GNU emacs
- next-error will handle it. The ending colon is taken from the
- gap which follows. */
+ /* Output the `reference' field, in such a way that GNU emacs
+ next-error will handle it. The ending colon is taken from the
+ gap which follows. */
- print_field (reference);
- putchar (':');
- print_spaces (reference_max_width
- + gap_size
- - (reference.end - reference.start)
- - 1);
- }
- else
- {
+ print_field (reference);
+ putchar (':');
+ print_spaces (reference_max_width
+ + gap_size
+ - (reference.end - reference.start)
+ - 1);
+ }
+ else
+ {
- /* Output the `reference' field and its following gap. */
+ /* Output the `reference' field and its following gap. */
- print_field (reference);
- print_spaces (reference_max_width
- + gap_size
- - (reference.end - reference.start));
- }
+ print_field (reference);
+ print_spaces (reference_max_width
+ + gap_size
+ - (reference.end - reference.start));
+ }
+ }
if (tail.start < tail.end)
{