Extracting values from comments

Is there an easy way to extract a sub-string within a comment and assign it directly to a variable with regular expressions?

For example, I would like to get the date out of a string that is structured like this:

AP 06[actionhistory]bypassed & mapped_address_changed & commented by admin (09-12-2010@9:02:13 AM)[/actionhistory]

Something that I was hopping to do was something along these lines

:local comment (AP 06[actionhistory]bypassed & mapped_address_changed & commented by admin (09-12-2010@9:02:13 AM)[/actionhistory]);
:local date [/system clock get date]
:local expire [extract value from comment variable somehow]
# expire variable would equal 09-12-2010
:if ($date > $expire) do={delete entry}

For text parsing to work correctly you have to have a set format. In this case, if there was never an @ anywhere but at the end of the date you could do the below:

:local comment [INSERT CODE TO RETRIEVE COMMENT HERE]
:local dateend [:find $comment "@"]
:local datebegin ($dateend - 10)
:local date [:pick $comment $datebegin $dateend]
:put $date