2010-05-13 Michael Snyder <msnyder@vmware.com>
* charset.c: White space. * c-lang.c: White space. * cli-out.c: White space. * coffread.c: White space. * complaints.c: White space. * completer.c: White space. * corefile.c: White space. * corelow.c: White space. * cp-abi.c: White space. * cp-namespace.c: White space. * cp-support.c: White space. * cp-valprint.c: White space. * c-typeprint.c: White space. * c-valprint.c: White space.
This commit is contained in:
parent
cc59ec59c8
commit
c5504eafbc
15 changed files with 115 additions and 22 deletions
10
gdb/c-lang.c
10
gdb/c-lang.c
|
@ -179,6 +179,7 @@ print_wchar (gdb_wint_t w, const gdb_byte *orig, int orig_len,
|
|||
int quoter, int *need_escapep)
|
||||
{
|
||||
int need_escape = *need_escapep;
|
||||
|
||||
*need_escapep = 0;
|
||||
if (gdb_iswprint (w) && (!need_escape || (!gdb_iswdigit (w)
|
||||
&& w != LCST ('8')
|
||||
|
@ -223,6 +224,7 @@ print_wchar (gdb_wint_t w, const gdb_byte *orig, int orig_len,
|
|||
{
|
||||
char octal[30];
|
||||
ULONGEST value;
|
||||
|
||||
value = extract_unsigned_integer (&orig[i], width, byte_order);
|
||||
/* If the value fits in 3 octal digits, print it that
|
||||
way. Otherwise, print it as a hex escape. */
|
||||
|
@ -236,6 +238,7 @@ print_wchar (gdb_wint_t w, const gdb_byte *orig, int orig_len,
|
|||
while (i < orig_len)
|
||||
{
|
||||
char octal[5];
|
||||
|
||||
sprintf (octal, "\\%.3o", orig[i] & 0xff);
|
||||
append_string_as_wide (octal, output);
|
||||
++i;
|
||||
|
@ -424,6 +427,7 @@ c_printstr (struct ui_file *stream, struct type *type, const gdb_byte *string,
|
|||
if (length == -1)
|
||||
{
|
||||
unsigned long current_char = 1;
|
||||
|
||||
for (i = 0; current_char; ++i)
|
||||
{
|
||||
QUIT;
|
||||
|
@ -504,6 +508,7 @@ c_printstr (struct ui_file *stream, struct type *type, const gdb_byte *string,
|
|||
/* Painful gyrations. */
|
||||
int j;
|
||||
char *s = xstrprintf (_(" <repeats %u times>"), reps);
|
||||
|
||||
for (j = 0; s[j]; ++j)
|
||||
{
|
||||
gdb_wchar_t w = gdb_btowc (s[j]);
|
||||
|
@ -881,6 +886,7 @@ convert_escape (struct type *type, const char *dest_charset,
|
|||
case 'U':
|
||||
{
|
||||
int length = *p == 'u' ? 4 : 8;
|
||||
|
||||
ADVANCE;
|
||||
if (!isxdigit (*p))
|
||||
error (_("\\u used with no following hex digits"));
|
||||
|
@ -908,6 +914,7 @@ parse_one_string (struct obstack *output, char *data, int len,
|
|||
while (data < limit)
|
||||
{
|
||||
char *p = data;
|
||||
|
||||
/* Look for next escape, or the end of the input. */
|
||||
while (p < limit && *p != '\\')
|
||||
++p;
|
||||
|
@ -1021,6 +1028,7 @@ evaluate_subexp_c (struct type *expect_type, struct expression *exp,
|
|||
else
|
||||
{
|
||||
int i;
|
||||
|
||||
/* Write the terminating character. */
|
||||
for (i = 0; i < TYPE_LENGTH (type); ++i)
|
||||
obstack_1grow (&output, 0);
|
||||
|
@ -1107,6 +1115,7 @@ c_language_arch_info (struct gdbarch *gdbarch,
|
|||
struct language_arch_info *lai)
|
||||
{
|
||||
const struct builtin_type *builtin = builtin_type (gdbarch);
|
||||
|
||||
lai->string_char_type = builtin->builtin_char;
|
||||
lai->primitive_type_vector
|
||||
= GDBARCH_OBSTACK_CALLOC (gdbarch, nr_c_primitive_types + 1,
|
||||
|
@ -1213,6 +1222,7 @@ cplus_language_arch_info (struct gdbarch *gdbarch,
|
|||
struct language_arch_info *lai)
|
||||
{
|
||||
const struct builtin_type *builtin = builtin_type (gdbarch);
|
||||
|
||||
lai->string_char_type = builtin->builtin_char;
|
||||
lai->primitive_type_vector
|
||||
= GDBARCH_OBSTACK_CALLOC (gdbarch, nr_cplus_primitive_types + 1,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue