The standard error for domestic cars reported by -ttest-
depends only on the data for domestic cars. The standard
error for the intercept of the regression depends on all
the data. So you can't expect exactly the same value.
The standard errors get a bit more similar (and indeed asymptotically
equivalent) if you specify the -robust- option for -regress- and the
-unequal- option for -ttest-. This is no coincidence, because, if -robust-
is not specified, then the standard error formulas used for -regress-
assume that variances are equal, and that you can therefore estimate the
population variability of smaller groups using the sample variability of
larger groups. The same assumption is used in calculating the standard
errors of the difference between 2 means in the equal-variance t-test.
However, it is not used by -ttest- for calculating the standard errors of
the means themselves, whether or not the -unequal- option is specified.