Make callers of `${Derived}::${base}()` use casts instead.

Fix #4124

This also introduce `BarCast::from_actual()` which is used for upper cast for dom's actual data types (non JS pointer values).