Don't sink last mainline statement if type object.

Avoids bogus errors when a role is the final thing in the mainline.