Mark Clements (HappyDog) schreef:
It doesn't, and it isn't... :-(
That said, the PHP_Compat PEAR module contains a PHP4 version of the clone function (providing you use clone($wgParser)) which I might try.
Alternatively, is there any harm in just using $wgParser directly? Do we have to make a copy?
I don't know. The only thing I know is that you have to be careful when calling Parser members inside a parser hook, because the parser kind of goes crazy when code called from Parser::parse() calls Parser::parse() with different arguments; Parser::recursiveTagParse() is the function you need in that case. I don't know what harm could be caused by using $wgParser directly in other cases; I guess you could try.
Roan Kattouw (Catrope)