This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] (v2) Add a "compact" mode to print_rtx_function


On 11/22/2016 02:37 PM, Jakub Jelinek wrote:
Can't it be done only if xloc.file contains any fancy characters?

Sure, but why? Strings generally get emitted with quotes around them, I don't see a good reason for filenames to be different, especially if it makes the output easier to parse.

If it does (where fancy should be anything other than [a-zA-Z/_0-9.-] or
some other reasonable definition, certainly space, quotes, backslash, etc. would count),
shouldn't we adjust it (e.g. use \" instead of ", handle control characters
etc.)?

The way I see it, spaces in filenames are regrettably somewhat common. Backslashes and quotes rather less so, to the point I really don't see a need to worry about them at the moment, and the necessary quoting could be added later if really necessary.


Bernd


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]