Add clone method to TargetData.

This commit is contained in:
Siu Kwan Lam 2013-01-03 10:17:23 -06:00
commit a6ed8d55f8

View file

@ -248,6 +248,9 @@ class TargetData(Pass):
def new(strrep):
return TargetData(_core.LLVMCreateTargetData(strrep))
def clone(self):
return TargetData.new(str(self))
def __str__(self):
return _core.LLVMTargetDataAsString(self.ptr)