The initialize function runs a string replace on three patterns-
\r\n -> \n
\r -> \n
\**\ -> Empty String
Two of these are meant to normalize newlines, and the third prevents a bug when a multiline comment has absolutely no content to it.
Replacing all three of these will improve performance by eliminating the str_replace call that scans the full javascript input. However, all three components have to be removed to do so- removing just one won't have significant performance benefits as the full scan will still need to occur.
The
initialize
function runs a string replace on three patterns-\r\n
->\n
\r
->\n
\**\
-> Empty StringTwo of these are meant to normalize newlines, and the third prevents a bug when a multiline comment has absolutely no content to it.
Replacing all three of these will improve performance by eliminating the
str_replace
call that scans the full javascript input. However, all three components have to be removed to do so- removing just one won't have significant performance benefits as the full scan will still need to occur.