class YARP::LibRubyParser::YPString
def self.with(filepath, &block)
def self.with(filepath, &block) pointer = FFI::MemoryPointer.new(SIZEOF) begin raise unless LibRubyParser.yp_string_mapped_init(pointer, filepath) yield new(pointer) ensure LibRubyParser.yp_string_free(pointer) pointer.free end end