A flashing check engine light means you have a serious misfire and are in danger of damaging your catalytic converter. Serious money there.
Overfilling the gas tank can cause the evaporation canister to become saturated with gas, also serious money. Some vehicles are more prone to this than others.
But this does not happen to a Subaru on just one occurrence. You should have been seeing a solid check engine light after just about every overfilling before this happened. It takes a prolonged habitual over filling to do serious damage.
Gas does evaporate so if you got the car to start a little later and run, then I'd say drive it for awhile and see if the check engine light goes out, although don't drive it if the CEL is flashing, but if it is solid, try driving it for a few weeks without overfilling the gas tank and see if the check engine light goes out on it's own. If it does, you are good to go as long as you stop overfilling the gas tank, don't even add a penny after the handle clicks off the first time.
If the light does not go out, go to a car parts store like AutoZone and have them read and erase the codes, if there are multiple codes. Then if the CEL comes on, get the codes read again, do not erase. But get the actual codes, the will start with a P and have four numbers following them. Some codes may have a suffix lowercase letter at the end. Post those here, do not accept the explanation from the guy who took the codes or the stock internet interpretations as some vehicles do not follow the standards code for code. Some vehicles will throw a code that is caused by something that is not on the standard or usual list of reasons.
For example, I had a 2002 Saturn. It threw a P0509 code. That is set by a high idle speed. The usual suspects listed were the IAC (idle air control), TPS (throttle position sensor) and a few others. But in this case, due to a combination of poor design and a change in the intake manifold gasket material starting in 2000, it was the intake gasket that was the problem. Only affected the 2000-2002 Saturns. Would never have know this if it wasn't for the Saturn forum I visited.