matthiasmullie / minify
Showing 1 of 2 files from the diff.
Other files ignored by Codecov

@@ -415,8 +415,19 @@
Loading
415 415
         * to be the for-loop's body... Same goes for while loops.
416 416
         * I'm going to double that semicolon (if any) so after the next line,
417 417
         * which strips semicolons here & there, we're still left with this one.
418 +
         * Note the special recursive construct in the three inner parts of the for:
419 +
         * (\{([^\{\}]*(?-2))*[^\{\}]*\})? - it is intended to match inline
420 +
         * functions bodies, e.g.: i<arr.map(function(e){return e}).length.
421 +
         * Also note that the construct is applied only once and multiplied
422 +
         * for each part of the for, otherwise it risks a catastrophic backtracking.
423 +
         * The limitation is that it will not allow closures in more than one
424 +
         * of the three parts for a specific for() case.
425 +
         * REGEX throwing catastrophic backtracking: $content = preg_replace('/(for\([^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*;[^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*;[^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*\));(\}|$)/s', '\\1;;\\8', $content);
418 426
         */
419 -
        $content = preg_replace('/(for\([^;\{]*;[^;\{]*;[^;\{]*\));(\}|$)/s', '\\1;;\\2', $content);
427 +
        $content = preg_replace('/(for\([^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*;[^;\{]*;[^;\{]*\));(\}|$)/s', '\\1;;\\4', $content);
428 +
        $content = preg_replace('/(for\([^;\{]*;[^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*;[^;\{]*\));(\}|$)/s', '\\1;;\\4', $content);
429 +
        $content = preg_replace('/(for\([^;\{]*;[^;\{]*;[^;\{]*(\{([^\{\}]*(?-2))*[^\{\}]*\})?[^;\{]*\));(\}|$)/s', '\\1;;\\4', $content);
430 +
420 431
        $content = preg_replace('/(for\([^;\{]+\s+in\s+[^;\{]+\));(\}|$)/s', '\\1;;\\2', $content);
421 432
        /*
422 433
         * Below will also keep `;` after a `do{}while();` along with `while();`
Files Complexity Coverage
src 118 99.56%
Project Totals (3 files) 118 99.56%

No yaml found.

Create your codecov.yml to customize your Codecov experience

Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading