This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v4] Use a proper C tokenizer to implement the obsolete typedefs test.
On 3/13/19 6:16 PM, Joseph Myers wrote:
> I'm seeing failures from build-many-glibcs.py for
> resource/check-obsolete-constructs:
>
> UnicodeDecodeError: 'ascii' codec can't decode byte 0xc2 in position 3198: ordinal not in range(128)
>
> This is with LC_ALL=C (and bits/resource.h headers containing UTF-8 µ in a
> comment). Code opening text files that might not be pure ASCII needs to
> specify an encoding explicitly to avoid depending on the locale tests are
> run with. There is also a case that the encoding specified should be
> ASCII - that installed headers should be required to be pure ASCII so they
> can be included in source files with any ASCII-compatible character set if
> compiling with -finput-charset= (which affects included headers as well as
> the main source file, so compiling "#include <sys/resource.h>" with
> -finput-charset=ascii currently fails).
Do we have a requirement that #incldue <sys/resources.h> be compilable with
-finput-charset=ascii?
Or to put it another way, who decides which sources files have to be ASCII
compatible?
Is the fix to fix bits/resource.h or the python opening of the file with
UTF-8 support?
--
Cheers,
Carlos.