Branch: refs/heads/blead
  Home:   https://github.com/Perl/perl5
  Commit: b1e3ba27cdcf1b4e2558f05ed4cc6780d2f208e1
      
https://github.com/Perl/perl5/commit/b1e3ba27cdcf1b4e2558f05ed4cc6780d2f208e1
  Author: Graham Knop <[email protected]>
  Date:   2022-03-15 (Tue, 15 Mar 2022)

  Changed paths:
    M sv.c
    M t/op/svflags.t

  Log Message:
  -----------
  always prevent setting POK flag when NV values are used as strings

Since PR #18958, values that start as IVs will not get their POK flags
set when they are used as strings. This is meant to aid in
serialization, allowing the "original" type of a value to be preserved.

For NV values, the POK flag was already usually not being set, because
the string form of a float could change based on the locale changing.
However, for Inf and NaN values, the POK flag would still be enabled.
Also, POK would be set for all floats if USE_LOCALE_NUMERIC was not
defined.

Update Perl_sv_2pv_flags to only enable the POKp flag when storing the
PV for Inf or NaN values, or all NVs when USE_LOCALE_NUMERIC is not
defined.


Reply via email to