Hi, this feature could be use to discart some unwanted objects, after some filtering perhaps.
But I think the point is that JS is a very dynamic language, we can change almost anything at anytime.
In example, here's a strange thing to do, but it works:
<div id="test"></div>
<script type='text/javascript'>
alert(document.getElementById("test"));
document.getElementById = function(id) {
alert("I don't want to find " + id);
return undefined;
}
alert(document.getElementById("test"));
</script>