Use grammar to parse quantity strings
In the current draft implementation of the quantity class, regular expressions are used to parse the quantity string. Using a grammar gives much more flexibility and allows for a more complex syntax in quantity strings.
A suitable package to parse the string based on a grammar is TatSu.