Closed chrisseaton closed 2 years ago
CRuby has a macro PASS_PASSED_BLOCK_HANDLER()
which it uses explicitly in a couple of places to pass the block. I'll add a spec and refactor our code to do the same sort of thing.
A fix for this has now been pushed to master.
This seems to be caused by a
block_given?
failing due to a method being very distant from where it's logically passed the block due C code in between.BlockGivenNode
here seems to be getting the frame of/Users/chrisseaton/Documents/nokogiri/lib/nokogiri/html4/document_fragment.rb:27
, which looks right, but indeed it doesn't have a block. How shouldrb_obj_call_init
be passing it, and how shouldxml_document_fragment.c#new
be passing it?Reproduce with
@flavorjones