This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regcomp.c: Vertically stack ternary
authorKarl Williamson <khw@cpan.org>
Mon, 1 Sep 2014 22:44:38 +0000 (16:44 -0600)
committerKarl Williamson <khw@cpan.org>
Sun, 7 Sep 2014 03:12:05 +0000 (21:12 -0600)
for legibility

regcomp.c

index 682ee5e..08b267b 100644 (file)
--- a/regcomp.c
+++ b/regcomp.c
@@ -14047,9 +14047,9 @@ parseit:
                     /* a bad range like \w-, [:word:]- ? */
                     if (namedclass > OOB_NAMEDCLASS) {
                         if (strict || (PASS2 && ckWARN(WARN_REGEXP))) {
-                            const int w =
-                                RExC_parse >= rangebegin ?
-                                RExC_parse - rangebegin : 0;
+                            const int w = RExC_parse >= rangebegin
+                                          ?  RExC_parse - rangebegin
+                                          : 0;
                             if (strict) {
                                 vFAIL4("False [] range \"%*.*s\"",
                                     w, w, rangebegin);