From 64daefd820ae1fdb1877cd96846baa477a0b159e Mon Sep 17 00:00:00 2001 From: Platonides Date: Fri, 5 Nov 2010 19:40:01 +0000 Subject: [PATCH] We have debug_print_backtrace() in PHP 5. Do not try to recreate it. --- maintenance/tests/parser/parserTest.inc | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/maintenance/tests/parser/parserTest.inc b/maintenance/tests/parser/parserTest.inc index afd2f811a2..da07b9c2a8 100644 --- a/maintenance/tests/parser/parserTest.inc +++ b/maintenance/tests/parser/parserTest.inc @@ -1162,7 +1162,8 @@ class ParserTest { $oldCapitalLinks = $wgCapitalLinks; $wgCapitalLinks = true; // We only need this from SetupGlobals() See r70917#c8637 - $title = Title::newFromText( self::chomp($name) ); + $name = self::chomp( $name ); + $title = Title::newFromText( $name ); if ( is_null( $title ) ) { wfDie( "invalid title ('$name' => '$title') at line $line\n" ); @@ -1171,9 +1172,7 @@ class ParserTest { $aid = $title->getArticleID( Title::GAID_FOR_UPDATE ); if ( $aid != 0 ) { - foreach(debug_backtrace() as $bt) { - echo "{$bt['file']}::{$bt['line']}\n"; - } + debug_print_backtrace(); wfDie( "duplicate article '$name' at line $line\n" ); } -- 2.20.1