I'm a little fuzzy on exactly what it is you want to match. In the example set you gave
[A000,A123-A456,A999-B000,B789-B888]
are you looking to match A000 and A456-A999, but NOT A999-B000? If you want the second one (A456-A999) matched, do you want it matched as A456 and A999 or as A456-A999?
davidj
Comment on Re: Need Set-like Regex for Perl and Java (golf OK)