Preserve 'extends' when the ShadowDOM polyfill patches document.register

Before this change this worked well in combination with the custom elements polyfill, however it failed with the native document.register.
Merge pull request #292 from sigmundch/patch-1

Preserve 'extends' when the ShadowDOM polyfill patches document.register