I don't like this, sorry.
I think deref->data_type is pretty definitely going to go away eventually. I'm not heavily opposed to shuffling things around in the meantime (although I don't see it as worthwhile). This does mean that 2/2 feels wrong, however.
More importantly, I don't like 1/2. hlsl_deref_compute_data_type() specifically feels wrong, it turns a simple idempotent function into something that now has to be called every time we construct a deref. It's not really clear to me how the code gets simpler either, if it does.