The hope for semantic HTML died the day they said "stop using <i>, use <em>", regardless of what the actual purpose of the italics was (it's usually not emphasis).
class Parent {};
class Child extends Parent {};
class Wrapper
{
Parent foo;
}
w = new Wrapper();
w.foo = new Child();
evaluate w.foo;
// static type: Parent
// dynamic type: Child