diff options
author | Tom Tromey <tom@tromey.com> | 2018-08-09 12:38:39 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2018-08-27 12:00:09 -0600 |
commit | 896a7aa6a119ce9d4872de87dabb81176489b1a3 (patch) | |
tree | 9e71c7fa2905b25b2a118b3fb8840cb2e6cba738 /gdb/linespec.c | |
parent | dd33d41d54654093fb5e0ac7a6edd0c6a8c998dd (diff) | |
download | gdb-896a7aa6a119ce9d4872de87dabb81176489b1a3.zip gdb-896a7aa6a119ce9d4872de87dabb81176489b1a3.tar.gz gdb-896a7aa6a119ce9d4872de87dabb81176489b1a3.tar.bz2 |
Avoid -Wnarrowing warnings from quote_char()
This adds a couple of casts to avoid -Wnarrowing warnings coming from
the use of quote_char().
gdb/ChangeLog
2018-08-27 Tom Tromey <tom@tromey.com>
* linespec.c (complete_linespec_component): Add cast to "char".
* completer.c (completion_tracker::build_completion_result): Add
cast to "char".
Diffstat (limited to 'gdb/linespec.c')
-rw-r--r-- | gdb/linespec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/linespec.c b/gdb/linespec.c index 73fbe4a..fd88007 100644 --- a/gdb/linespec.c +++ b/gdb/linespec.c @@ -2894,7 +2894,7 @@ complete_linespec_component (linespec_parser *parser, new "quote" char. */ if (tracker.quote_char ()) { - char quote_char_str[2] = { tracker.quote_char () }; + char quote_char_str[2] = { (char) tracker.quote_char () }; fn = reconcat (fn, fn, quote_char_str, (char *) NULL); tracker.set_quote_char (':'); |