Test, validate and match regular expressions
This PCRE regex matches custom loop declarations, specifically lines starting with [FOR] followed by a variable name, an equals sign, and numbers separated by a character. It also matches lines containing [NEXT] followed by a word variable name, utilizing regex recursion (?1) to match the same word structure. It is useful for parsing custom configuration or templating syntax that defines iterative blocks or macros.