Introduce DEFINE_ELEMENT_DATA_TYPE_CASTS, and use it

As a step to use toFoo, this cl introduces DEFINE_ELEMENT_DATA_TYPE_CASTS, which generates
toUniqueElementData() and toShareableElementData(). Those functions will detect bad type cast.

BUG=309516

Review URL: https://codereview.chromium.org/405923002

git-svn-id: svn://svn.chromium.org/blink/trunk@178643 bbb929c8-8fbe-4397-9dbb-9b2b20218538