... and, also note that your first capture element -- the dreaded dot-star (which is anything, any number of times including zero)-- is greedy, so the second match would never occur, even if the code compiled because the first match would have swallowed everying in your (then-current) line of data.
Regexen can, of course, be "greedy" without dot-star. Greedy means the regex element -- in this case, using a star/asterisk quantifier -- will match as much data as possible until a new line (or other construct not present in your regex) shuts them down.
Super Search this site (or use big G) for "greed" and/or "greedy" for examples.
If I've misconstrued your question or the logic needed to answer it, I offer my apologies to all those electrons which were inconvenienced by the creation of this post.