[Perl/perl5] e0993a: locale.c: Don't compile unreachable code
Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: e0993acfe19e64409299c35a5a1d6b86e560e7c4 https://github.com/Perl/perl5/commit/e0993acfe19e64409299c35a5a1d6b86e560e7c4 Author: Karl Williamson Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M locale.c Log Message: --- locale.c: Don't compile unreachable code The switch statement affected by this commit has numerous case: statements within it. Prior to this commit, if any of them was required, all would be compiled. But in many Configurations only a portion of them are required. Skip the others. This takes advantage of the fact that an undefined preprocessor macro evaluates to 0 (false) when used in an #if conditional. In this case, #foo_AVAIL is often undefined, so evaluates to false. (Although locale_table.h could be changed to always define it to 'false', should it become necessary.)
[Perl/perl5] 92d2bd: lib/locale.t: Reorder a list
Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: 92d2bd9e36afc11ede7eadc5a17fb84532536abb https://github.com/Perl/perl5/commit/92d2bd9e36afc11ede7eadc5a17fb84532536abb Author: Karl Williamson Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M lib/locale.t Log Message: --- lib/locale.t: Reorder a list This is to make the next commits have fewer differences Commit: a0c2c9541fe74ce836462ae99142c6306c4a4f10 https://github.com/Perl/perl5/commit/a0c2c9541fe74ce836462ae99142c6306c4a4f10 Author: Karl Williamson Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M lib/locale.t Log Message: --- lib/locale.t: Use a list for display item source This file displays some items related to the current locale; haphazardly. This commit creates a list that is then used instead of individual statements. It then becomes easy to add items to display Commit: 0185ec19d7a2d02fd87601365f85ad2afac799aa https://github.com/Perl/perl5/commit/0185ec19d7a2d02fd87601365f85ad2afac799aa Author: Karl Williamson Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M lib/locale.t Log Message: --- lib/locale.t: Add more debug output This file tries out every locale it can find on the system. And, in debug mode, outputs information about each locale, in addition to the testing. This commit adds at least one bit of information from every possible information type. So, for example, it displays the name of the first month of the year (but not the rest of the months), the name of the first day of the week (but not the rest), etc. This enables someone to get a good idea what a locale is like. Compare: https://github.com/Perl/perl5/compare/527e765cf579...0185ec19d7a2
[Perl/perl5] 527e76: win32/GNUmakefile: enable warnings for gcc
Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: 527e765cf579b4374cbeb60151f3d7bbb138bdf1 https://github.com/Perl/perl5/commit/527e765cf579b4374cbeb60151f3d7bbb138bdf1 Author: Tony Cook Date: 2024-01-17 (Wed, 17 Jan 2024) Changed paths: M win32/GNUmakefile Log Message: --- win32/GNUmakefile: enable warnings for gcc Warnings are already enabled for MSVC, so enable them for GCC too. -Wformat is disabled since the default "__printf__" format checker doesn't understand the C99-isms like "%zd", resulting in many spurious warnings. The __gnu_printf__ checker does understand them, but it doesn't understand the Windows specific "%I64d" and similar formats.
[Perl/perl5] 5bb402: loc_tools: Generally return at least C locale
Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: 5bb402b5171850353df8e2f0e23826ee98b839ed https://github.com/Perl/perl5/commit/5bb402b5171850353df8e2f0e23826ee98b839ed Author: Karl Williamson Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M t/loc_tools.pl Log Message: --- loc_tools: Generally return at least C locale If a category exists on the system, but we are supposed to keep it in the C locale, it still is testable as C or POSIX. Prior to this commit, it wasn't considered testable, and as a result tests in our suite were wrongly skipped.
[Perl/perl5] ed7993: Perl_amagic_call(): don't assume non-NULL PL_op
Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: ed79937e388a8232abe29c064ca4863b6b2cc1be https://github.com/Perl/perl5/commit/ed79937e388a8232abe29c064ca4863b6b2cc1be Author: David Mitchell Date: 2024-01-16 (Tue, 16 Jan 2024) Changed paths: M gv.c Log Message: --- Perl_amagic_call(): don't assume non-NULL PL_op This line in Perl_amagic_call(): U8 gimme = (force_scalar || PL_op->op_type == OP_MULTICONCAT) relies on either PL_op always being non-null, or for the times that PL_op is null, that force_scalar always ends up being true. As it happens, qr// with constant overloading calls Perl_amagic_call() with a null PL_op, but also with method=string_amg, which happens to set force_scalar. Add a check for PL_op being non-null, partly to future-proof the code, but mainly to shut up Coverity, which rightly pointed out that some new code added by me with v5.39.6-107-g547324acdb *does* check for PL_op being non-null earlier in the function, and if there's one thing Coverity can't abide, it's inconsistency.