https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124641
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |fw at gcc dot gnu.org
--- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Note, the testsuite contains quite a lot of files which aren't valid UTF-8.
Though, at least in some of those it is clearly intentional:
testsuite/ada/acats-4/tests/cxa/cxa3005.a
testsuite/ada/acats-4/tests/cxa/cxa3007.a
testsuite/ada/acats-4/tests/cxa/cxa4036.a
testsuite/c-c++-common/cpp/Winvalid-utf8-1.c
testsuite/c-c++-common/cpp/Winvalid-utf8-2.c
testsuite/c-c++-common/cpp/Winvalid-utf8-3.c
testsuite/c-c++-common/diagnostic-format-sarif-file-bad-utf8-pr109098-1.c
testsuite/c-c++-common/diagnostic-format-sarif-file-bad-utf8-pr109098-2.c
testsuite/c-c++-common/diagnostic-format-sarif-file-bad-utf8-pr109098-3.c
testsuite/c-c++-common/diagnostic-format-sarif-file-valid-CP850.c
testsuite/g++.dg/cpp23/Winvalid-utf8-1.C
testsuite/g++.dg/cpp23/Winvalid-utf8-10.C
testsuite/g++.dg/cpp23/Winvalid-utf8-11.C
testsuite/g++.dg/cpp23/Winvalid-utf8-12.C
testsuite/g++.dg/cpp23/Winvalid-utf8-2.C
testsuite/g++.dg/cpp23/Winvalid-utf8-3.C
testsuite/g++.dg/cpp23/Winvalid-utf8-4.C
testsuite/g++.dg/cpp23/Winvalid-utf8-5.C
testsuite/g++.dg/cpp23/Winvalid-utf8-6.C
testsuite/g++.dg/cpp23/Winvalid-utf8-7.C
testsuite/g++.dg/cpp23/Winvalid-utf8-8.C
testsuite/g++.dg/cpp23/Winvalid-utf8-9.C
testsuite/g++.dg/ext/offsetof1.C
testsuite/g++.dg/lookup/using13.C
testsuite/g++.dg/other/default4.C
testsuite/g++.dg/parse/condexpr1.C
testsuite/g++.old-deja/g++.mike/net48.C
testsuite/g++.old-deja/g++.oliva/thunk1.C
testsuite/g++.old-deja/g++.other/crash41.C
testsuite/g++.old-deja/g++.other/friend6.C
testsuite/g++.old-deja/g++.other/friend7.C
testsuite/gcc.c-torture/execute/20000227-1.c
testsuite/gcc.dg/diagnostic-input-charset-1.c
testsuite/gcc.dg/encoding-issues-bytes.c
testsuite/gcc.dg/encoding-issues-unicode.c
testsuite/gcc.dg/cpp/strify2.c
testsuite/gcc.dg/cpp/ucnid-7-utf8.c
testsuite/gcc.dg/ucnid-16-utf8.c
testsuite/gdc.dg/bom_UTF16BE.d
testsuite/gdc.dg/bom_UTF16LE.d
testsuite/gdc.dg/bom_UTF32BE.d
testsuite/gdc.dg/bom_UTF32LE.d
testsuite/gdc.dg/bom_characters.d
testsuite/gdc.test/compilable/test13512.d
testsuite/gdc.test/fail_compilation/fail6458.d
testsuite/gfortran.dg/achar_2.f90
testsuite/gfortran.dg/achar_3.f90
testsuite/gfortran.dg/alloc_comp_default_init_2.f90
testsuite/gfortran.dg/altreturn_4.f90
testsuite/gfortran.dg/altreturn_5.f90
testsuite/gfortran.dg/anint_1.f90
testsuite/gfortran.dg/bom_UTF-32.f90
testsuite/gfortran.dg/bom_UTF16-BE.f90
testsuite/gfortran.dg/bom_UTF16-LE.f90
testsuite/gfortran.dg/bom_error.f90
testsuite/gfortran.dg/data_implied_do_1.f90
testsuite/gfortran.dg/extended_char_comparison_1.f
testsuite/gfortran.dg/illegal_char.f90
testsuite/gfortran.dg/initialization_12.f90
testsuite/gfortran.dg/g77/19981216-0.f
testsuite/gfortran.dg/int_1.f90
testsuite/gfortran.dg/intrinsic_actual_4.f90
testsuite/gfortran.dg/string_0xfe_0xff_1.f90
testsuite/gnat.dg/array13.adb
testsuite/rust/compile/macros/builtin/invalid_utf8
testsuite/rust/compile/broken_utf8.rs
In array13.adb I strongly doubt it is intentional.
Anyway, scanasm.exp has fconfigure $fd -encoding $file_encoding but that
clearly doesn't trigger during make check-gnat.
Anyway, dejagnu utils.exp has
proc grep { args } {
...
set i 0
set fd [open $file r]
while { [gets $fd cur_line] >= 0 } {
...
(and various other spots in gcc *.exp files similarly) which doesn't do
fconfigure at all.
Wonder if we don't need in all such places for $tcl_version "9.0" and later do
fconfigure $fd -profile tcl8
or
fconfigure $fd -profile replace
because -profile strict is now the default.
So
if {[package vsatisfies [package provide Tcl] 9.0-]} {
fconfigure $fd -profile replace
}
would need to be added in various spots after open.