Merge "StringUtils: Add a utility for checking if a string is a valid regex"
[lhc/web/wiklou.git] / includes / parser / Preprocessor_Hash.php
index f7f37ac..7c372ee 100644 (file)
  */
 // phpcs:ignore Squiz.Classes.ValidClassName.NotCamelCaps
 class Preprocessor_Hash extends Preprocessor {
-
-       /**
-        * @var Parser
-        */
-       public $parser;
-
        const CACHE_PREFIX = 'preprocess-hash';
        const CACHE_VERSION = 2;
 
@@ -628,7 +622,9 @@ class Preprocessor_Hash extends Preprocessor {
                                }
                                $i += $count;
                        } elseif ( $found == 'close' ) {
+                               /** @var PPDStackElement_Hash $piece */
                                $piece = $stack->top;
+                               '@phan-var PPDStackElement_Hash $piece';
                                # lets check if there are enough characters for closing brace
                                $maxCount = $piece->count;
                                if ( $piece->close === '}-' && $curChar === '}' ) {