Even though I've looked through multiple examples of how to capture a repeated group. I cant seem to be able to understand it correctly for my case to make it work.
use ((?:([a-z_0-9]*)\.)*)(\w*);
As shown in the above example, I wish to capture the package name in segments so that use ieee.std_logic_1164.all;
returns [IEEE, std_logic_1164, all]
etc.
Currently my regex returns [ieee.std_logic_1164., std_logic_1164, all]
which is wrong.
I am missing something from the expression I've done. It seems that I can only capture the last iteration of the repeated group even though I've encapsulated my repeated section in another capturing group according to the specification.
Regards