Unit Tests: Extra test with nested optional subpatterns
Use PREG_OFFSET_CAPTURE for the regex matching, and rely on the offsets it returns to extract the parameters (= a cleaner solution than #9 for #8).