Class: FFI::Clang::Lib::CXCursor

Inherits:
Struct
  • Object
show all
Defined in:
lib/ffi/clang/lib/cursor.rb

Overview

FFI struct representing a cursor in the libclang AST.

Instance Method Summary collapse

Instance Method Details

#dupObject

Create a deep copy of this cursor in Ruby-managed memory.



389
390
391
392
393
# File 'lib/ffi/clang/lib/cursor.rb', line 389

def dup
	copy = self.class.new
	copy.to_ptr.put_bytes(0, self.to_ptr.read_bytes(self.class.size))
	copy
end