From: Tim Starling Date: Mon, 15 Aug 2016 06:02:53 +0000 (+1000) Subject: Remove all assert() calls with string parameters X-Git-Tag: 1.31.0-rc.0~6059^2 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dcompta/comptes/journal.php?a=commitdiff_plain;h=6a04d86149aca3171ba3a028bc98b108bdb0d73f;p=lhc%2Fweb%2Fwiklou.git Remove all assert() calls with string parameters These fail when HHVM is in RepoAuthoritative mode Change-Id: Ifb1628f8269b2b651154b740b95cc14163a1b186 --- diff --git a/includes/parser/Preprocessor_DOM.php b/includes/parser/Preprocessor_DOM.php index a28c0aa439..5da7cd7441 100644 --- a/includes/parser/Preprocessor_DOM.php +++ b/includes/parser/Preprocessor_DOM.php @@ -539,7 +539,7 @@ class Preprocessor_DOM extends Preprocessor { } elseif ( $found == 'line-end' ) { $piece = $stack->top; // A heading must be open, otherwise \n wouldn't have been in the search list - assert( '$piece->open == "\n"' ); + assert( $piece->open === "\n" ); $part = $piece->getCurrentPart(); // Search back through the input to see if it has a proper close. // Do this using the reversed string since the other solutions diff --git a/includes/parser/Preprocessor_Hash.php b/includes/parser/Preprocessor_Hash.php index 012288fa4c..8a4637ea1e 100644 --- a/includes/parser/Preprocessor_Hash.php +++ b/includes/parser/Preprocessor_Hash.php @@ -475,7 +475,7 @@ class Preprocessor_Hash extends Preprocessor { } elseif ( $found == 'line-end' ) { $piece = $stack->top; // A heading must be open, otherwise \n wouldn't have been in the search list - assert( '$piece->open == "\n"' ); + assert( $piece->open === "\n" ); $part = $piece->getCurrentPart(); // Search back through the input to see if it has a proper close. // Do this using the reversed string since the other solutions