Patch on its way.
Created attachment 14798 [details]
I am a little uneasy about this patch and wouldn't mind some harsh reviewing of it. The part I am uneasy about is the changing of the NodeFilter parameter of Document::createNodeIterator and Document::createTreeWalker to be regular pointers instead of PassRefPtrs. I did this becuase it makes generating a lot easier and that is how parameters are generally passed for the bindings. If there is any slowdown or other issues that this might cause I am sure I can come up with a work around in the bindings scripts, but I thought I would check if this way was OK first.
Comment on attachment 14798 [details]
Landed in r22035.