IE8だけクラッシュさせる技

I've isolated a strange issue with IE8 regarding the CSS :before and :after pseudo elements. The issue occurs when you set one pseudo elements position to absolute and the other's to relative; see the following example:

<style type="text/css">
  div:before { content: ""; position: relative; }
  div:after { content: ""; position: absolute; }
</style>
<div>stuff</div>

IE8 crashes. Literally. No error, nothing helpful - just the dreaded "Internet Explorer has stopped working" and the Windows 7 attempt to relaunch it. To be clear, the error occurs when switching to the IE8 Browser and Rendering Mode of IE9. When i loaded the example in IETester's IE8 page, no error occurred.

I will test this in an actual IE8 asap, but my question is: why does this happen? Is it an IE8 bug? Maybe a side effect of some sort of position bug? Isn't IE8 supposed to render pseudo elements?

css - IE8 Bug with pseudo elements - Stack Overflow


嵌るところだった。