Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<head>
<title>createContextualFragment should not crash when the end node is a processing instruction</title>
<link rel="author" title="Simon Wülker" href="mailto:simon.wuelker@arcor.de">
</head>
<body>
<script>
let pi = document.createProcessingInstruction("xml-stylesheet", 'href="mycss.css" type="text/css"');
let range = document.createRange();
range.setEnd(pi, 0)
range.createContextualFragment("<div>A</div>");
</script>
</body>