characters with octal escapes.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49891
138bc75d-0d04-0410-961f-
82ee72b054a4
+2002-02-19 Zack Weinberg <zack@codesourcery.com>
+
+ * toplev.c (output_quoted_string): Write unprintable
+ characters with octal escapes.
+
2002-02-19 David Edelsohn <edelsohn@gnu.org>
* config/rs6000/rs6000.h (CONDITIONAL_REGISTER_USAGE): Set
putc ('\"', asm_file);
while ((c = *string++) != 0)
{
- if (c == '\"' || c == '\\')
- putc ('\\', asm_file);
- putc (c, asm_file);
+ if (ISPRINT (c))
+ {
+ if (c == '\"' || c == '\\')
+ putc ('\\', asm_file);
+ putc (c, asm_file);
+ }
+ else
+ fprintf (asm_file, "\\%03o", c);
}
putc ('\"', asm_file);
#endif