This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
run/locale.t: Remove redundant block
authorKarl Williamson <khw@cpan.org>
Wed, 14 May 2014 02:53:11 +0000 (20:53 -0600)
committerKarl Williamson <khw@cpan.org>
Sun, 1 Jun 2014 03:22:45 +0000 (21:22 -0600)
This has { { foo } }
Only one level is necessary. outdents.

t/run/locale.t

index 0c58a63..5e72526 100644 (file)
@@ -236,25 +236,23 @@ EOF
                         1);
             }
             else {
-                {
-                    local $ENV{LC_ALL} = "invalid";
-                    local $ENV{LC_NUMERIC} = "invalid";
-                    local $ENV{LANG} = "invalid";
-
-                    # Can't turn off the warnings, so send them to /dev/null
-                    fresh_perl_is(<<"EOF", 4.2, { stderr => "devnull" },
-                        if (\$ENV{LC_ALL} ne "invalid") {
-                            print "$difference\n";
-                            exit 0;
-                        }
-                        use locale;
-                        use POSIX qw(locale_h);
-                        setlocale(LC_NUMERIC, "");
-                        my \$in = 4.2;
-                        printf("%g", \$in);
+                local $ENV{LC_ALL} = "invalid";
+                local $ENV{LC_NUMERIC} = "invalid";
+                local $ENV{LANG} = "invalid";
+
+                # Can't turn off the warnings, so send them to /dev/null
+                fresh_perl_is(<<"EOF", 4.2, { stderr => "devnull" },
+                    if (\$ENV{LC_ALL} ne "invalid") {
+                        print "$difference\n";
+                        exit 0;
+                    }
+                    use locale;
+                    use POSIX qw(locale_h);
+                    setlocale(LC_NUMERIC, "");
+                    my \$in = 4.2;
+                    printf("%g", \$in);
 EOF
-                    'C locale is used if LC_ALL, LC_NUMERIC, LANG are invalid');
-                }
+                'C locale is used if LC_ALL, LC_NUMERIC, LANG are invalid');
             }
         }