Index: trunk/extensions/RegexFun/RELEASE-NOTES |
— | — | @@ -1,7 +1,7 @@ |
2 | 2 | Changelog: |
3 | 3 | ========== |
4 | 4 | |
5 | | - * (trunk) -- Version 1.0.2 alpha |
| 5 | + * December 5, 2011 -- Version 1.0.2 |
6 | 6 | - Limit won't exceed early when 'e' flag with many backrefs in replacement is used extensivelly. |
7 | 7 | - It's possible to use the 'Regex Fun' regex system with advanced flags within other extensions. |
8 | 8 | - Performance increased for executing huge numbers of the same regex on different strings. |
— | — | @@ -48,5 +48,5 @@ |
49 | 49 | - '#regexquote' delimiter set to '/' by default. |
50 | 50 | - '#regex' no longer returns its value as parsed wikitext (option 'noparse' => false) instead |
51 | 51 | the 'e' flag can be used (although not exactly the same). |
52 | | - - contributed under ISC License, maintained in wikimedia.org svn.======= |
| 52 | + - contributed under ISC License, maintained in wikimedia.org svn. |
53 | 53 | |
\ No newline at end of file |
Index: trunk/extensions/RegexFun/RegexFun.php |
— | — | @@ -8,7 +8,7 @@ |
9 | 9 | * Support: http://www.mediawiki.org/wiki/Extension_talk:Regex_Fun |
10 | 10 | * Source code: http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/RegexFun |
11 | 11 | * |
12 | | - * @version: 1.0.2 alpha |
| 12 | + * @version: 1.0.2 |
13 | 13 | * @license: ISC license |
14 | 14 | * @author: Daniel Werner < danweetz@web.de > |
15 | 15 | * |
— | — | @@ -273,7 +273,8 @@ |
274 | 274 | $lastMatches = self::getLastMatches( $parser ); |
275 | 275 | $output = ( preg_match( $pattern, $subject, $lastMatches ) ? $lastMatches[0] : '' ); |
276 | 276 | self::setLastMatches( $parser, $lastMatches ); |
277 | | - } else { |
| 277 | + } |
| 278 | + else { |
278 | 279 | // replace mode: |
279 | 280 | $limit = (int)$limit; |
280 | 281 | |
— | — | @@ -298,13 +299,13 @@ |
299 | 300 | } |
300 | 301 | |
301 | 302 | /** |
302 | | - * 'preg_replace' like function but can handle special modifiers 'e' and 'r'. |
| 303 | + * 'preg_replace'-like function but can handle special modifiers 'e' and 'r'. |
303 | 304 | * |
304 | 305 | * @param string &$pattern |
305 | 306 | * @param string $replacement |
306 | 307 | * @param string $subject |
307 | 308 | * @param int $limit |
308 | | - * @param Parser &$parser if 'e' flag should be allowed, a parser objecdt for parsing is required. |
| 309 | + * @param Parser &$parser if 'e' flag should be allowed, a parser object for parsing is required. |
309 | 310 | * @param array $allowedSpecialFlags all special flags that should be handled, by default 'e' and 'r'. |
310 | 311 | */ |
311 | 312 | public static function doPregReplace( |