I suggested accessing named capture groups myself:
https://forums.mirc.com/ubbthreads.php/topics/259456/Retrieving_named_captures_with#Post259456While your idea may be good, I wouldn't want to be forced to assign the value to a local variable to access it.
If the problem is with accessing $regml(ex) itself rather than wanting support for named capture groups, I think it would be better to improve $regmlex to support a @window/command parameter like $hfind, which makes it better for looping over capture groups.