Did the:
no warnings 'experimental:smartmatch’;
work A-OK?
Should this not be `no warnings ‘experimental:switch’;` ?
I don’t mind making the changes but I am doing this a little blind since I don’t do perl…
Jon
Jon Murphy jon.murphy@ipfire.org
On Jan 16, 2023, at 3:28 PM, Bernhard Bitsch bbitsch@ipfire.org wrote:
Hi,
just a little annotation after reading the Perl docs.
Am 16.01.2023 um 21:34 schrieb Jon Murphy:
- add single line to code: no warnings 'experimental';
- corrects this issue: https://lists.ipfire.org/pipermail/development/2022-December/015113.html
Signed-off-by: Jon Murphy jon.murphy@ipfire.org
html/cgi-bin/services.cgi | 1 + 1 file changed, 1 insertion(+) diff --git a/html/cgi-bin/services.cgi b/html/cgi-bin/services.cgi index 3c0f27f99..0d06ab5fe 100644 --- a/html/cgi-bin/services.cgi +++ b/html/cgi-bin/services.cgi @@ -21,6 +21,7 @@ use strict; use feature "switch"; +no warnings 'experimental';
Because the warnings originate from the switch statement only, we should be specific:
no warnings 'experimental:smartmatch';
# enable only the following on debugging purpose #use warnings; #use CGI::Carp 'fatalsToBrowser';
Further the line should be placed here. This creates the right sequence if the debugging mode is switched on ( by uncommenting these lines ).
Regards, Bernhard